What is the output of the following C Program?
![]()
Practice Arrays – What is the output of the following C Program?
#include
void main()
{
int a[10];
printf("%d",*a+1-*a+3);
} ![]()
Practice Arrays – What is the output of the following C Program?
#include
void main()
{
int a[10];
printf("%d",*a+1-*a+3);
} ![]()
Practice Control Instructions – What is the output of the following C Program?
#include
void main()
{
while(1){
if(printf("%d",printf("%d")))
break;
else
continue;
}
} ![]()
Practice Expressions – What will be the output of the below C program.
#include
int main()
{
int i=i++,j=j++,k=k++;
printf("%d%d%d",i,j,k);
return 0;
} ![]()
Practice Strings – What will be the output of the below C program.
#include
void main()
{
int i;
char a[]="";
if(printf("%s
",a))
printf("Ok Done
");
else
printf("Forget it
");
} ![]()
Practice Variable Number of Arguments – What will be the output of the below C program.
#include
int main()
{
static int i=5;
if(--i){
main();
printf("%d ",i);
}
return 0;
} ![]()
Practice Basic Concept – What will be the output of the below C program.
#include
int main(){
int a= 0;
int b = 20;
char x =1;
char y =10;
if(a,b,x,y)
printf("hello");
return 0;
} ![]()
Practice Functions – What will be output of the following “c” code?
#include
int AX = 0;
int main()
{
int i=0;
i = abc();
printf("%d",i);
return 0;
}
abc()
{
AX = 1000;
return AX;
} ![]()
Practice Basic Concept – What is the output of the following C Program?
#include
void main()
{
int y;
scanf("%d",&y); // Given Input is 2000
if( (y%4==0 && y%100 != 0) || y%100 == 0 )
printf("%d is a leap year");
else
printf("%d is not a leap year");
} ![]()
Practice Expressions – What will be output of the following “c” code?
#include
long fu(int);
char vect[]={1,2,3,4,5};
void main(){
int i=1;
i=fu(++i)+ ++vect[++i]+ ++i+fu(i++);
printf("%d",i);
}
long fu(int x){
return x*3;
} ![]()
Practice Expressions – What will be output of the following “c” code?
#include
int main()
{
int i=5;
printf("%d %d %d %d %d %d",i++,i--,++i,--i,i);
return 0;
} ![]()
Practice Basic Concept – What is the output of the following C Program?
#include
void main(){
int z;
z=(5,3,2);
printf("%d",z);
} ![]()
Practice Expressions – What will be output of the following “c” code?
#include
void main(){
int num,a=5;
num=---a;
printf("%d %d",num,a);
} ![]()
Practice Expressions – What will be output of the following “c” code?
#include
void main(){
int a[]={5,10,15};
int i=0,num;
num=a[++i]+ ++i+(++i);
printf("%d",num);
} ![]()
Practice Basic Concept – What is the output of the following C Program?
#include
int main()
{
printf("
ab");
printf("si");
printf("
ha");
return 0;
} ![]()
Practice Control Instructions – What will be output of the following “c” code?
void main()
{
int c[ ]={2.8,3.4,4,6.7,5};
int j,*p=c,*q=c;
for(j=0;j<5;j++) {
printf(" %d ",*c);
++q;
}
for(j=0;j<5;j++){
printf(" %d ",*p);
++p;
}
}