NANDHOO
.
Learning Paths
Dashboard
Sign In
Home
Dashboard
C Programming Engineering Mastery
Sample Beginner Programs
Quiz
Chapter Quiz: Sample Beginner Programs
Beginner Programs Quiz
Complete this assessment with 100% score to master this chapter.
01
In the provided Fibonacci program, which data type is used for 't1' and 't2' to handle large numbers?
int
short
long long
float
02
In a prime number check, why do we only need to test divisors up to the square root of N?
Because C can't handle larger numbers
To optimize the algorithm by reducing the number of iterations
It's a requirement of the C standard
Because prime numbers are always small
03
What is the time complexity of the simple Bubble Sort algorithm?
O(log N)
O(N)
O(N log N)
O(N^2)
04
In the calculator program, why is a space used before '%c' in 'scanf(" %c", &op)'?
It's just for readability
To skip any leading whitespace or newline characters from the previous input
It makes the code faster
It's a syntax requirement
05
What is the result of '5 % 2' in C?
2.5
2
1
0
Submit Answers
Back to Lesson
Next Chapter