ExamVeda
Login
Home
1
What is the format identifier for "static a = 20.5;"?
Discuss
Answer & Solution
Answer: Option B
No explanation is given for this question. Let's Discuss on Board
2
What will be the output of the following C code?
#include <stdio.h>
#define COLD
int main()
{
    #ifdef COLD
    printf("COLD\t");
    #undef COLD
    #endif
    #ifdef COLD
    printf("HOT\t");
    #endif
}
Discuss
Answer & Solution
Answer: Option B
No explanation is given for this question. Let's Discuss on Board
3
What will be the output of the following C code?
#include <stdio.h>
int *m()
{
    int *p = 5;
    return p;
}
void main()
{
    int *k = m();
    printf("%d", k);
}
Discuss
Answer & Solution
Answer: Option A
No explanation is given for this question. Let's Discuss on Board
4
Which directory the compiler first looks for the file when using #include?
Discuss
Answer & Solution
Answer: Option B
No explanation is given for this question. Let's Discuss on Board
5
What will be the output of the following C code?
#include <stdio.h>
#define foo(x, y) x / y + x
int main()
{
    int i = -6, j = 3;
    printf("%d\n",foo(i + j, 3));
    return 0;
}
Discuss
Answer & Solution
Answer: Option C
No explanation is given for this question. Let's Discuss on Board
6
What will be the output of the following C code?
#include <stdio.h>
int m()
{
    printf("hello");
}
void main()
{
    int k = m();
    printf("%d", k);
}
Discuss
Answer & Solution
Answer: Option A
No explanation is given for this question. Let's Discuss on Board
7
What will be the output of the following C code?
#include <stdio.h>
int main()
{
    register auto int i = 10;
    i = 11;
    printf("%d\n", i);
}
Discuss
Answer & Solution
Answer: Option B
No explanation is given for this question. Let's Discuss on Board
8
What will be the output of the following C code?
#include <stdio.h>
void main()
{
    m();
}
void m()
{
    printf("hi");
    m();
}
Discuss
Answer & Solution
Answer: Option C
No explanation is given for this question. Let's Discuss on Board
9
What will be the output of the following C code?
#include <stdio.h>
void foo();
int main()
{
    void foo(int);
    foo(1);
    return 0;
}
void foo(int i)
{
    printf("2 ");
}
Discuss
Answer & Solution
Answer: Option A
No explanation is given for this question. Let's Discuss on Board
10
Which of the following is an external variable in the following C code?
#include <stdio.h>
int func (int a)
{
    int b;
    return b;
}
int main()
{
    int c;
    func (c);
}
int d;
Discuss
Answer & Solution
Answer: Option D
No explanation is given for this question. Let's Discuss on Board