
Conquer C
Authored by Priyanka PS
Other
University
Used 3+ times

AI Actions
Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...
Content View
Student View
40 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What will be the output of the program if value 126 given to scanf()?
#include<stdio.h>
int main()
{
int i;
printf("%d\n", scanf("%d", &i));
return 0;
}
126
2
1
5
2.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What will be the output of the program ?
#include<stdio.h>
int main()
{
FILE *ptr;
char i;
ptr = fopen("myfile.c", "r");
while((i=fgetc(ptr))!=NULL)
printf("%c", i);
return 0;
}
Print the contents of file "myfile.c"
Print the contents of file "myfile.c" upto NULL character
Infinite loop
Error in program
3.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What is the output of the program given below ?
#include<stdio.h>
int main()
{
enum status { pass, fail, atkt};
enum status stud1, stud2, stud3;
stud1 = pass;
stud2 = atkt;
stud3 = fail;
printf("%d, %d, %d\n", stud1, stud2, stud3);
return 0;
}
0, 1, 2
1, 2, 3
0, 2, 1
1, 3, 2
4.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What is the output of the program
#include<stdio.h>
int main()
{
int x = 10, y = 20, z = 5, i;
i = x < y < z;
printf("%d\n", i);
return 0;
}
0
1
Error
None of these
5.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What is the output of the program?
#include<stdio.h>
int main()
{
union a
{
int i;
char ch[2];
};
union a u;
u.ch[0] = 3;
u.ch[1] = 2;
printf("%d, %d, %d\n", u.ch[0], u.ch[1], u.i);
return 0;
}
3, 2, 515
515, 2, 3
3, 2, 5
None of these
6.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What will be the output of the program?
#include<stdio.h>
int main()
{
int i=4, j=-1, k=0, w, x, y, z;
w = i || j || k;
x = i && j && k;
y = i || j &&k;
z = i && j || k;
printf("%d, %d, %d, %d\n", w, x, y, z);
return 0;
}
1, 1, 1, 1
1, 1, 0, 1
1, 0, 0, 1
1, 0, 1, 1
7.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What will be the output of the program?
#include<stdio.h>
int main()
{
char ch;
ch = 'A';
printf("The letter is");
printf("%c", ch >= 'A' && ch <= 'Z' ? ch + 'a' - 'A':ch);
printf("Now the letter is");
printf("%c\n", ch >= 'A' && ch <= 'Z' ? ch : ch + 'a' - 'A');
return 0;
}
The letter is a
Now the letter is A
The letter is A
Now the letter is a
Error
None of above
Access all questions and much more by creating a free account
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?
Similar Resources on Wayground
35 questions
ABELE Quiz 1 (Hydrometeorology)
Quiz
•
University
40 questions
A&P 2 EXAM 1
Quiz
•
University
35 questions
NCAG - U1 - Extracting info test
Quiz
•
11th Grade - University
41 questions
Nagarjuna
Quiz
•
University
40 questions
CCTS
Quiz
•
University
40 questions
Business Marketing Quiz
Quiz
•
University
40 questions
MTE BBA-III SEM FOFM
Quiz
•
University
45 questions
แบบทดสอบวิชาไมโครคอนโทรลเลอร์
Quiz
•
KG - Professional Dev...
Popular Resources on Wayground
15 questions
Fractions on a Number Line
Quiz
•
3rd Grade
20 questions
Equivalent Fractions
Quiz
•
3rd Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
22 questions
fractions
Quiz
•
3rd Grade
20 questions
Main Idea and Details
Quiz
•
5th Grade
20 questions
Context Clues
Quiz
•
6th Grade
15 questions
Equivalent Fractions
Quiz
•
4th Grade
20 questions
Figurative Language Review
Quiz
•
6th Grade
Discover more resources for Other
12 questions
IREAD Week 4 - Review
Quiz
•
3rd Grade - University
23 questions
Subject Verb Agreement
Quiz
•
9th Grade - University
7 questions
Force and Motion
Interactive video
•
4th Grade - University
7 questions
Renewable and Nonrenewable Resources
Interactive video
•
4th Grade - University
5 questions
Poetry Interpretation
Interactive video
•
4th Grade - University
19 questions
Black History Month Trivia
Quiz
•
6th Grade - Professio...
15 questions
Review1
Quiz
•
University
15 questions
Pre1
Quiz
•
University