What will be output of the following “c” code?


Loading

Practice Variable Number of Arguments – What will be output of the following “c” code?


#include

void main(){

float a=5.2;

if(a==5.2)

printf("Equal");

else if(a<5.2)

printf("Less than");

else

printf("Greater than");

}

What will be output of the following “C” code?

Loading

Practice Expressions – What will be output of the following “C” code?


#include
void main()
{
int i=10;
printf("%d,%d",++i,++i);
}

What will be the size of these structures?

			  		

Loading

Practice Structures, Unions, Enums – What will be the size of these structures?


#include
struct S1 {
char c;
int i[2];
double v;
} SA1;
struct S2 {
double x;
int i[2];
char c;
} SA2;
int main()
{
printf("
sizeof S1 %d : Sizeof S2 %d ",sizeof(SA1),sizeof(SA2));
return 0;
}

Note:char takes 1 byte, int takes 4 bytes, double takes 8 bytes

What will be the output of the program ?

			  		

Loading

Practice Arrays – What will be the output of the program ?


int main()
{
int a[5] = {5, 1, 15, 20, 25};
int i, j, m;
i = ++a[1];
j = a[1]++;m = a[i++];
printf("%d, %d, %d", i, j, m);
return 0;
}

Is there any difference between following declarations?

A

Loading

Practice Functions – Is there any difference between following declarations?

A : extern int fun();
B : int fun();