Which loop is most suitable to first perform the operation and then test the
condition?
EC8393 - Fundamentals of Data Structures in C
Quiz
•
Computers
•
University
•
Hard
Jothi P
Used 19+ times
FREE Resource
25 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
2 mins • 1 pt
Which loop is most suitable to first perform the operation and then test the
condition?
while loop
for loop
do while loop
All of the mentioned
2.
MULTIPLE CHOICE QUESTION
2 mins • 1 pt
What is the output of the below code snippet
#include<stdio.h>
main()
{
printf("%d", -11%2);
}
1
5
-1
-5
3.
MULTIPLE CHOICE QUESTION
2 mins • 1 pt
Which of the following function is more appropriate for reading in a multi-word string?
puts()
gets()
printf()
scanf()
4.
MULTIPLE CHOICE QUESTION
2 mins • 1 pt
What will be the output of the following C code?
#include <stdio.h>
int main()
{
int a = 1, b = 1, c;
c = a++ + b;
printf("%d, %d", a, b);
}
a = 1, b = 1
a = 1, b = 2
a = 2, b = 2
a = 2, b = 1
5.
MULTIPLE CHOICE QUESTION
2 mins • 1 pt
What will be the output of the following C code?
#include <stdio.h>
void main()
{
int x = 5;
if (x < 1)
printf("hello");
if (x == 5)
printf("hi");
else
printf("no");
}
hi
hello
no
error
6.
MULTIPLE CHOICE QUESTION
2 mins • 1 pt
Array can be considered as set of elements stored in consecutive memory locations but having __________.
same data type
different data type
same scope
none
7.
MULTIPLE CHOICE QUESTION
2 mins • 1 pt
Determine the output:
#include<stdio.h>
int main()
{
int arr[10] = {0,1,2,[7]=7,8,9};
printf("%d ", arr[5]);
printf("%d ", arr[8]);
}
0 0
8 0
0 8
5 8
20 questions
EST102 : PROGRAMMING IN C TEST 1
Quiz
•
University
20 questions
C - Strings
Quiz
•
University
25 questions
C Quiz 1
Quiz
•
University
20 questions
1st Year quiz
Quiz
•
University
20 questions
PRA UAS - Dasar Dasar Pemrograman 2023
Quiz
•
University
20 questions
C Quest 2.0
Quiz
•
University
20 questions
C-QUEST QUIZ BEE
Quiz
•
University
30 questions
C-Language Q1
Quiz
•
University
15 questions
Character Analysis
Quiz
•
4th Grade
17 questions
Chapter 12 - Doing the Right Thing
Quiz
•
9th - 12th Grade
10 questions
American Flag
Quiz
•
1st - 2nd Grade
20 questions
Reading Comprehension
Quiz
•
5th Grade
30 questions
Linear Inequalities
Quiz
•
9th - 12th Grade
20 questions
Types of Credit
Quiz
•
9th - 12th Grade
18 questions
Full S.T.E.A.M. Ahead Summer Academy Pre-Test 24-25
Quiz
•
5th Grade
14 questions
Misplaced and Dangling Modifiers
Quiz
•
6th - 8th Grade