What does the following declaration mean?
int (*ptr)[5];
Sample
Quiz
•
Computers
•
University
•
Hard
Gunjan Verma
Used 2+ times
FREE Resource
20 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
10 sec • 1 pt
What does the following declaration mean?
int (*ptr)[5];
2.
MULTIPLE CHOICE QUESTION
10 sec • 1 pt
Which of the following can be checked in a switch statement?
Integer values
Character values
Both a and b
Floating-point values
3.
MULTIPLE CHOICE QUESTION
20 sec • 1 pt
Identify the error in the code:
for (int i = 0; i < 5; i--) {
printf("%d", i);
}
Infinite loop
Syntax Error
i is undeclared
Logical error
4.
MULTIPLE CHOICE QUESTION
10 sec • 1 pt
What is the correct syntax for declaring a function that does not return a value?
a) int func();
b) void func();
c) func();
d) function func();
5.
MULTIPLE CHOICE QUESTION
10 sec • 1 pt
Which type of variables can retain their values between function calls?
a) auto
b) register
c) static
d) extern
6.
MULTIPLE CHOICE QUESTION
10 sec • 1 pt
Which of the following is an incorrect function prototype?
a) int func(int a, int b);
b) float func(int, float);
c) double func(double);
d) int func(a, b);
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the output of the following code?
int arr[] = {1, 2, 3, 4};
printf("%d", *(arr + 2));
a) 1
b) 2
c) 3
d) 4
15 questions
C++ Quiz-1
Quiz
•
University
25 questions
C Programing
Quiz
•
University
16 questions
C-Extended
Quiz
•
University
20 questions
C programming syntax quiz
Quiz
•
University
25 questions
Compro. Final1/64 part2
Quiz
•
University
20 questions
BS TEST2
Quiz
•
University
20 questions
C - Structures
Quiz
•
University
15 questions
Coding club Summit Online Quiz
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