What will be the output of given program?#include<stdio.h>void main(){int a=1;if("%d=hello", a);} no error no output 1 0 complier error TRUE ANSWER : ? YOUR ANSWER : ?
What will be printed if the following code is executed?void main(){ int x=0; for( ; ; ) { if( x++ == 4 ) break; continue; } printf("x=%d", x);} x=4 x=0 Error x=1 x=5 TRUE ANSWER : ? YOUR ANSWER : ?
short testarray[4][3] = { {1}, {2,3}, {4,5,6}};printf("%d", sizeof(testarray));Assuming a short is two bytes long, what will be printed by the above code? 6 12 7 It will not compile because not enough initializers are given 24 TRUE ANSWER : ? YOUR ANSWER : ?
char* myfunc(char *ptr){ ptr+=3; return(ptr);}void main(){ char *x, *y; x = "EXAMVEDA"; y = myfunc(x); printf("y=%s", y);}What will be printed when the sample code above is executed? y=AMVEDA y=MVEDA y=EDA y=VEDA y=EXAMIANS TRUE ANSWER : ? YOUR ANSWER : ?
What will be the output of the program?#include<stdio.h>#define int char void main(){ int i = 65; printf("sizeof(i)=%d", sizeof(i));} sizeof(i)=2 Compiler Error None of These sizeof(i)=1 TRUE ANSWER : ? YOUR ANSWER : ?
Which of the following statements should be used to obtain a remainder after dividing 3.14 by 2.1 ? rem = modf(3.14, 2.1); rem = 3.14 % 2.1; rem = fmod(3.14, 2.1); Remainder cannot be obtain in floating point division. TRUE ANSWER : ? YOUR ANSWER : ?
Determine Output:void main(){ static int i=5; if(--i){ main(); printf("%d ", i); }} None of These Infinite Loop 5 4 3 2 1 0 0 0 0 TRUE ANSWER : ? YOUR ANSWER : ?
What will be the output of the program ?#include#includevoid main(){ char str[] = "Exam\0Veda"; printf("%s", str);} Exam\0Veda Exam Exam Veda None of these Veda TRUE ANSWER : ? YOUR ANSWER : ?
Find the output of the following program.void main(){ int i=10; /* assume address of i is 0x1234ABCD */ int *ip=&i; int **ipp=&&i; printf("%x,%x,%x", &i, ip, *ipp); } 0x1234ABCD, 10, 10 0x1234ABCD, 0x1234ABCD, 10 0x1234ABCD, 0x1234ABCD, 0x1234ABCD Syntax error Runtime error TRUE ANSWER : ? YOUR ANSWER : ?
The default parameter passing mechanism is call by value result call by value call by reference None of these. TRUE ANSWER : ? YOUR ANSWER : ?