Functions in C Programming MCQ (Multiple Choice Questions And Answers)
Are you preparing for the next job interviews? If yes, trust me this post will help you also we'll suggest you check out a big collection for Programming Full Forms that may help you in your interview:
List of Programming Full Forms
void myshow(int *);
void main()
{
int a=10;
printf("%d ", a);
myshow(&a);
printf("%d", a);
}
void myshow(int *k)
{
*k=20;
}
- 10 30
- 20 20
- 10 10
- 10 20
#include
int func()
{
return (double)(char)5.0;
}
- int
- double
- char
- No output
- it increases the code size
- no type checking will be done
- recursion is not possible
- All of the above
void main()
{
static int x;
if (x++ < 2)
main();
}
- No output
- main() is called twice
- Run Time Error
- Varies
int x = 5;
void main()
{
int x = 3;
printf("%d", x);
{
x = 4;
}
printf("%d", x);
}
- 3 3
- 4 4
- 3 4
- Runtime error