Total Ten Questions. Each Question 2Marks.
Total Time 15 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. Watch the videos again and take the test after one 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> int main(void) { int ch; scanf("%d",&ch); switch(ch,ch+1) { case 1: printf("1"); break; case 2: printf("2"); break; default: printf("3"); break; } 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 i=5,j=7; if(i+j>5) { j=i+2; if(j<5) { printf("%d",i); } else { printf("%d",j); } } else { printf("%d",i+1); } return 0; }
CorrectIncorrect -
Question 3 of 10
3. Question
Q3) What will be the output if the folowing numbers are given as input to number 122,567,789,543,536,999.
#include <stdio.h> int main(void) { float s=0,c=0,a=0,number; scanf("%f",&number); while(number!=999) { s=s+number; c=c+1; scanf("%f",&number); } a=s/c; printf("%f",a); return 0; }
CorrectIncorrect -
Question 4 of 10
4. Question
Q4) What will be the output if the value 2030 is given input to n?
#include <stdio.h> int main(void) { int n,ec=0,nr,d; scanf("%d",&n); nr=n; while(nr) { d=nr%10; if(d!=0) ec++; nr=nr/10; } printf("%d",ec); return 0; }
CorrectIncorrect -
Question 5 of 10
5. Question
Q5) What is the output displayed by the below program?
#include <stdio.h> int main(void) { int n,i; scanf("%d",&n); for(i=0;i<n;i++) { printf("%d",i); i--; } return 0; }
CorrectIncorrect -
Question 6 of 10
6. Question
Q6) What is the output displayed by the below program?
#include <stdio.h> int main(void) { int i=0,j; while(i<2) { j=0; while(j<=3*i) { printf("%d",j); printf(" "); j=j+3; } printf("\n"); i=i+1; } return 0; }
CorrectIncorrect -
Question 7 of 10
7. Question
Q7) What is the output displayed by the below program if num is given value 256?
#include <stdio.h> int main(void) { int count=0,num; scanf("%d",&num); while(num) { count++; num>>=1; } printf("%d",count); return 0; }
CorrectIncorrect -
-
Question 8 of 10
8. Question
Q8) consider the following c code . Assume unsigned long int is 64 bit.
The value print by the above code with n value given as 2power40?int main() { unsigned long int i,j=0,sum=0,n; for(i=n;i>1;i=i/2) j++; for( ;j>1;j=j/2) sum++; printf(“%d”,sum); }
CorrectIncorrect -
-
Question 9 of 10
9. Question
Q9) What is the output displayed by the below program?
#include <stdio.h> int main(void) { float sum=0.0,j=1.0,i=2.0; while(i/j>0.0625) { j=j+j; sum=sum+i/j; printf("%f",sum); } return 0; }
CorrectIncorrect -
-
Question 10 of 10
10. Question
Q10) What is the output displayed by the below program?
#include <stdio.h> int main(void) { int a,b,c,d=6; for(a=1;a<=2;a++) { for(b=a;b<=2;b++) { for(c=b;c<=2;c++) printf("%d",d); } } return 0; }
CorrectIncorrect