Elearning , Interview Questions And Answers

Google

int f=x; float ans=0.0; f *=x*y; ans=x/3.0+y/3; printf("%d %.2f",f,ans); } Q22) Find the output for the following C program #include<stdio.h> void main(void); { double dbl=20.4530,d=4.5710,dblvar3; double dbln(void); dblvar3=dbln(); printf("%.2f\t%.2f\t%.2f\n",dbl,d,dblvar3); } double dbln(void) { double dblvar3; dbl=dblvar3=4.5; return(dbl+d+dblvar3); } Q23) Find the output for the following C program #include<stdio.h> static int i=5; void main(void) { int sum=0; do { sum+=(1/i); }while(0<i--); } Q24) Find the output for the following C program #include<stdio.h> void main(void) { int oldvar=25,newvar=-25;