What is the output of this program?
#include
#define x 3
int main()
{
int i;
i = x*x*x;
printf("%d",i);
return 0;
}
#include
#define ISEQUAL(X, Y) X == Y
int main()
{
#if ISEQUAL(X, 0)
printf("Geeks");
#else
printf("Quiz");
#endif
return 0;
}
Output of the above program?
Which header file should be included to use functions like malloc() and calloc()?
Why to use fflush() library function?
What is the output of this C code?
#include
void main()
{
int x = 0;
int *ptr = &5;
printf("%p\n", ptr);
}
What will be the output of the following C code?
#include
enum sanfoundry
{
a=1,b,c,d,e
};
int main()
{
printf("%d",b*c+e-d);
}
Which of the following share a similarity in syntax? 1. Union 2. Structure 3. Arrays 4. Pointers
Size of the array need not be specified, when
Devices that let the computer communicate with you.
Computer output may consist of
A Laser printer is a
If the two strings are identical, then strcmp() function returns
The function strsp() is the complement of strcspn().
What is the output of this C code?
int x = 5;
void main()
{
int x = 3;
m();
printf("%d", x);
}
void m()
{
x = 8;
n();
}
void n()
{
printf("%d", x);
}
What is the scope of an external variable?
What is the output of this C code?
int x = 5;
void main()
{
int x = 3;
printf("%d", x);
{
x = 4;
}
printf("%d", x);
}
What is the output of this C code?
int x;
void main()
{
printf("%d", x);
}
What will be the output of the following program?
#include< stdio>
int main()
{
register int I = 2;
static char ch = ‘A’;
auto float j;
int k;
k = ++ch && I;
k = ++ch;
j = i-- + ++k * 2;
printf(“%d %f”, k , j);
return 0;
}
Which of the following is used as a primary storage device?
What is the output of the below code snippet?
#include
main()
{
unsigned x = 5, y=&x, *p = y+0;
printf("%u",*p);
}
Total number of questions : 20
Number of answered questions : 0
Number of unanswered questions : 20
What is the output of this program?
#include
#define x 3
int main()
{
int i;
i = x*x*x;
printf("%d",i);
return 0;
}
Your Answer : (Not Answered)
Correct Answer : A
No answer description available for this question.
#include
#define ISEQUAL(X, Y) X == Y
int main()
{
#if ISEQUAL(X, 0)
printf("Geeks");
#else
printf("Quiz");
#endif
return 0;
}
Output of the above program?
Your Answer : (Not Answered)
Correct Answer : A
No answer description available for this question.
Which header file should be included to use functions like malloc() and calloc()?
Your Answer : (Not Answered)
Correct Answer : B
No answer description available for this question
Why to use fflush() library function?
Your Answer : (Not Answered)
Correct Answer : A
As defined Use of fflush(stdin) in C : fflush() is typically used for output stream only. Its purpose is to clear (or flush) the output buffer and move the buffered data to console (in case of stdout) or disk (in case of file output stream).
What is the output of this C code?
#include
void main()
{
int x = 0;
int *ptr = &5;
printf("%p\n", ptr);
}
Your Answer : (Not Answered)
Correct Answer : D
No answer description available for this question.
What will be the output of the following C code?
#include
enum sanfoundry
{
a=1,b,c,d,e
};
int main()
{
printf("%d",b*c+e-d);
}
Your Answer : (Not Answered)
Correct Answer : B
Since arithmetic operations are allowed on enum constants, hence the expression given is evaluates. b*c+e-d = 2*3+5-4 = 6+5-4 = 7
Which of the following share a similarity in syntax? 1. Union 2. Structure 3. Arrays 4. Pointers
Your Answer : (Not Answered)
Correct Answer : B
No answer description available for this question
Size of the array need not be specified, when
Your Answer : (Not Answered)
Correct Answer : A
int arr[] = {1,2,3}; In this case size of array need not to be specified when initialization is a part of defination.
Devices that let the computer communicate with you.
Your Answer : (Not Answered)
Correct Answer : B
No answer description available for this question.
Computer output may consist of
Your Answer : (Not Answered)
Correct Answer : A
No answer description available for this question.
A Laser printer is a
Your Answer : (Not Answered)
Correct Answer : A
No answer description available for this question.
If the two strings are identical, then strcmp() function returns
Your Answer : (Not Answered)
Correct Answer :
The function strsp() is the complement of strcspn().
Your Answer : (Not Answered)
Correct Answer : A
Both strcspn() and strpbrk() perform the same function. Only strspn() the return values differ. The function strspn() is the complement of strcspn() .
What is the output of this C code?
int x = 5;
void main()
{
int x = 3;
m();
printf("%d", x);
}
void m()
{
x = 8;
n();
}
void n()
{
printf("%d", x);
}
Your Answer : (Not Answered)
Correct Answer : A
No answer description available for this question.
What is the scope of an external variable?
Your Answer : (Not Answered)
Correct Answer : D
No answer description available for this question.
What is the output of this C code?
int x = 5;
void main()
{
int x = 3;
printf("%d", x);
{
x = 4;
}
printf("%d", x);
}
Your Answer : (Not Answered)
Correct Answer : D
No answer description available for this question.
What is the output of this C code?
int x;
void main()
{
printf("%d", x);
}
Your Answer : (Not Answered)
Correct Answer :
What will be the output of the following program?
#include< stdio>
int main()
{
register int I = 2;
static char ch = ‘A’;
auto float j;
int k;
k = ++ch && I;
k = ++ch;
j = i-- + ++k * 2;
printf(“%d %f”, k , j);
return 0;
}
Your Answer : (Not Answered)
Correct Answer : C
No answer description available for this question.
Which of the following is used as a primary storage device?
Your Answer : (Not Answered)
Correct Answer : A
No answer description available for this question.
What is the output of the below code snippet?
#include
main()
{
unsigned x = 5, y=&x, *p = y+0;
printf("%u",*p);
}
Your Answer : (Not Answered)
Correct Answer : D
5, as p holds the address of x which is y+0
Total number of questions : 20
Number of answered questions : 0
Number of unanswered questions : 20
We'll write only best content for you