Top C C++ Errors Interview Questions :: ALLInterview.com http://www.allinterview.com Top C C++ Errors Interview Questions en-us how to convert decimal to binary in c using while loop without using http://www.allinterview.com/showanswers/80689.html Void main() { int dec,i=1,rem,res=0; Printf("Enter the Value %d",&dec); while(dec!=0) { rem=dec%2; dec=dec/2; res=res+(i * 1); i=i*10; } printf("The Binary value is %d&q Given an int variable n that has been initialized to a positive val http://www.allinterview.com/showanswers/73797.html total=0; k=1; do { total=total+k*k*k; k++; }while(k<=n) Given an int variable n that has already been declared and initiali http://www.allinterview.com/showanswers/73796.html //1st method.. there is no use of j.as explained below int j,n=psitive value; do { cout<<"*"; n--; }while(n!=0); //2nd we can use j.. int j=0; do { cout<<"*"; j++; }while(j!=n); void main() { for(int i=0;i&lt;5;i++); printf(&quot;%d&quot;,i); } http://www.allinterview.com/showanswers/72734.html Answer is 5.......... Given that two int variables, total and amount , have been declare http://www.allinterview.com/showanswers/73794.html total= 0; scanf("%d",&amount); total +=amount; scanf("%d",&amount); total +=amount; scanf("%d",&amount); total +=amount; loop1: { x=i&lt;n?(i++):0; printf(&quot;%d&quot;,i); exit(x); http://www.allinterview.com/showanswers/58234.html Error- misplaced continue. void main() { int i=1; printf(&quot;%d%d%d&quot;,i,++i,i++); } Ca http://www.allinterview.com/showanswers/72737.html 3 3 1 To generate the series 1+3+5+7+... using C program http://www.allinterview.com/showanswers/71183.html #include<stdio.h> #include<conio.h> void main() { int n,i=1,sum=0; clrscr(); printf("enter the value for n:"); scanf("%d",&n); while(i<=n) { sum=sum+i; i=i+2; } printf("the series is =%d") Given that two int variables, total and amount, have been declared, w http://www.allinterview.com/showanswers/73795.html total=0; cin>>amount; while (amount>=0) { total=total+amount; cin>>amount; } who was the present cheif governor of reserve bank of india http://www.allinterview.com/showanswers/73167.html Mr.Subbarao write a profram for selection sort whats the error in it? http://www.allinterview.com/showanswers/72524.html //program for selection sort #include<stdio.h> #include<conio.h> #define MX 100 void selection(int [], int); void selection(int a[],int n) { int minindx,t; int i,j; for(i=0;i<n-1;i++) { minindx=i; for(j=i+1;i<n;j Find the error (2.5*2=5) (a) X=y=z=0.5,2.0-5.75 (b) s=15; http://www.allinterview.com/showanswers/77290.html If a float variable multiply by an integer, it will give answer in float. So the answer should be in float. main() { char c; for(c=&#039;A&#039;;c&lt;=&#039;Z&#039;;c++) http://www.allinterview.com/showanswers/84507.html NO ERRORS but result........... UINT i,j; i = j = 0; i = ( i++ &gt; ++j ) ? i++ : i--; explain pl http://www.allinterview.com/showanswers/74123.html (i++ > j++) gives 0 because 0 > 0 is false so it return 0. before returning 0 i is 1 ,but it is overwrite by 0. In the Conditional operator false means ,it executes i++; so i is 1. printy(a=3,a=2) http://www.allinterview.com/showanswers/69263.html if we want to show result as a=3,a=2..then it ll be written as printf("a=3,a=2");