Total Ten Questions. Each Carry 2 Marks.
Total Time 20 Min.
Quiz Summary
0 of 10 Questions completed
Questions:
Information
You have already completed the quiz before. Hence you can not start it again.
Quiz is loading…
You must sign in or sign up to start the quiz.
You must first complete the following:
Results
Results
0 of 10 Questions answered correctly
Your time:
Time has elapsed
You have reached 0 of 0 point(s), (0)
Earned Point(s): 0 of 0, (0)
0 Essay(s) Pending (Possible Point(s): 0)
Categories
- Not categorized 0%
-
If you score less than 16 marks. Please watch the concepts and example videos again and take test after a week.
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
- Current
- Review
- Answered
- Correct
- Incorrect
-
Question 1 of 10
1. Question
Q1) What is the output displayed by the below program?
#include <stdio.h> void f(int *a,int *b) { *a=*a+1; *b=*b+1; } int main(void) { int c=10,d=11; c=c+1; d=d+1; f(&c,&d); printf("%d",c+d); return 0; }
CorrectIncorrect -
-
Question 2 of 10
2. Question
Q2) What is the output displayed by the below program?
#include <stdio.h> int main(void) { int *a,z=10; a=&z; z=z+++*a; printf("%d",(*a)++); return 0; }
CorrectIncorrect -
-
Question 3 of 10
3. Question
Q3) What is the output displayed by the below program?
#include <stdio.h> void f(int *a,int n) { int i; for(i=0;i<n-1;i++) a[i]+=(a+1)[0]; } int main(void) { int b[10]={1,2,3,4},i; f(b,4); for(i=0;i<4;i++) printf("%d",b[i]); return 0; }
CorrectIncorrect -
Question 4 of 10
4. Question
Q4) What is the output displayed by the below program?
#include <stdio.h> int main(void) { int a=0,b=1,c=2; *((a+1==1)?&b:&a)=a?b:c; printf("%d%d%d",a,b,c); return 0; }
CorrectIncorrect -
Question 5 of 10
5. Question
Q5) What is the output displayed by the below program?
#include <stdio.h> int f(int *a,int *b) { int sum; sum=*a+*b; *b=*a; return *a=sum-*b; } int main(void) { int i=0,j=1,k=2,l; l=(i++ || f(&j,&k)); printf("%d%d%d%d",i,j,k,l); return 0; }
CorrectIncorrect -
Question 6 of 10
6. Question
Q6) What is the output displayed by the below code?
#include <stdio.h> void f(int *p,int m) { m=m-5; *p=*p-m; } int main(void) { int i=10,j=5; f(&i,j); printf("%d",i+j); return 0; }
CorrectIncorrect -
-
Question 7 of 10
7. Question
Q7) What is the output displayed by the below program?( GV means Garbage Value)
#include <stdio.h> int main(void) { int *ptr; int x; ptr=&x; *ptr=0; printf("%d",x); printf("%d",*ptr); *ptr+=5; printf("%d",x); printf("%d",*ptr); (*ptr)++; printf("%d",x); printf("%d",*ptr); return 0; }
CorrectIncorrect -
Question 8 of 10
8. Question
Q8) What is the output displayed by the below program?
#include <stdio.h> int main(void) { float a[5]={1.1,2.1,3.1,5.1,6.1}; float *ptr1=&a[0]; float *ptr2=ptr1+3; printf("%.1f",*ptr2); printf("%d",ptr2-ptr1); return 0; }
CorrectIncorrect -
Question 9 of 10
9. Question
Q9) What is the output displayed by the below program?
#include <stdio.h> int main(void) { int a[]={1,2,3,4,5,6}; int *p=a; int *p1=a+5; printf("%d",p1-p); printf("%d",(char *)p1-(char *)p); return 0; }
CorrectIncorrect -
Question 10 of 10
10. Question
Q10) What is the output displayed by the below code?
#include <stdio.h> int i=0,j=1; void f(int *p,int *q) { p=q; *p=2; } int main(void) { f(&i,&j); printf("%d%d",i,j); return 0; }
CorrectIncorrect -