Q161
Open question#include <stdio.h>
int *m();
void main()
{
int *k = m();
printf("hello ");
printf("%d", k[0]);
}
int *m()
{
int a[2] = {5, 8};
return a;
}Select an option to see the answer and solution.
Practice every MCQ with options. Use Show answers when you want the correct option and solution.
223
Questions
9/12
Page
Pick an option on a question to see the right answer and solution.
Q161
Open question#include <stdio.h>
int *m();
void main()
{
int *k = m();
printf("hello ");
printf("%d", k[0]);
}
int *m()
{
int a[2] = {5, 8};
return a;
}Select an option to see the answer and solution.
Q162
Open questionSelect an option to see the answer and solution.
Q163
Open questionSelect an option to see the answer and solution.
Q164
Open questionSelect an option to see the answer and solution.
Q165
Open question#include <stdio.h>
int x = 5;
void main()
{
int x = 3;
m();
printf("%d", x);
}
void m()
{
x = 8;
n();
}
void n()
{
printf("%d", x);
}Select an option to see the answer and solution.
Q166
Open question#include <stdio.h>
int main()
{
extern ary1[];
printf("scope rules\n");
}Select an option to see the answer and solution.
Q167
Open question#include <stdio.h>
static int x;
void main()
{
int x;
printf("x is %d", x);
}Select an option to see the answer and solution.
Q168
Open questionSelect an option to see the answer and solution.
Q169
Open questionSelect an option to see the answer and solution.
Q170
Open questionSelect an option to see the answer and solution.
Q171
Open question#include <stdio.h>
int main()
{
auto i = 10;
const auto int *p = &i;
printf("%d\n", i);
}Select an option to see the answer and solution.
Q172
Open question#include <stdio.h>
void main()
{
int x;
}Select an option to see the answer and solution.
Q173
Open questionSelect an option to see the answer and solution.
Q174
Open question#include <stdio.h>
int main()
{
printf("%d", d++);
}
int d = 10;Select an option to see the answer and solution.
Q175
Open question#include <stdio.h>
int main()
{
void foo(), f();
f();
}
void foo()
{
printf("2 ");
}
void f()
{
printf("1 ");
foo();
}Select an option to see the answer and solution.
Q176
Open questionSelect an option to see the answer and solution.
Q177
Open questionSelect an option to see the answer and solution.
Q178
Open question#include <stdio.h>
void main()
{
m();
void m()
{
printf("hi");
}
}Select an option to see the answer and solution.
Q179
Open question#include <stdio.h>
int main()
{
void foo();
printf("1 ");
foo();
}
void foo()
{
printf("2 ");
}Select an option to see the answer and solution.
Q180
Open question#include <stdio.h>
static int x = 5;
void main()
{
int x = 9;
{
x = 4;
}
printf("%d", x);
}Select an option to see the answer and solution.