C language is the first language that most programmers get introduced to programming. The quiz below is a sample test to show you the questions you would expect to get in your papers come exam time. Give it a try and all the best as you continue on the programing journey.
If-else
Goto
While
Switch-case
External
Automatic
Register
Define
# define pie = 22/7
#define pie 22/7
#define pie= 3.142
# Define pie 22/7
0
Cannot be predicted
1
2
More than one default allowesd
Default case, if used, should be the last case
Default case, if used, can be placed anywhere
Default case must be present
2
3
Any number
1
Cache
Memory
Processor registers
Virtual memory
The initialization and increment parts of a for statement can be empty
The body of do-while statement can be empty
The expression in the condition part of a for statement can be empty
The initialization part of a for statement cannot have more than one initialization
No
Unpredictable
Yes
Error
After main
After block
Before main
Within block
While loop is executed atleast once
Do . while loop is executed at least once
While loop is executed only if the condition is true
Dowhile loop is ececuted only if the condition is true
\“well done \”
Well done
“ well done”
\ well done \
0
Run-time error
Undefined
Compilation error
Dynamically identifies based on largest index used in program
Does not require to be specified
Assume default size as ‘0’
Requires to be specified
A type and size
A type, name, value and size
A name and type
A size and value
Defined
Neither initialized nor defined
Initialized and defined
Initialized
6 bytes
24 bytes
12 bytes
48 bytes
Loop construct
Two way decision
Multiway decision
One-way decision
Sizeof (datatype) * 2
Size of (datatype) * size of used array elements
Sizeof (datatype) * sizeof array
Size of (array) * datatype
None of the element are initialized to zero
Only first row elements are initialized to zero
Only last row elements are initialized to zero
All the array elements are initialized to zero
For(a=‘A’; a
For(a=‘A’; a
For(a=‘a’; a
For(a=’A’ a
Data type
Datatype and size
Run-time requirement
Size
Character constant
A floating point number
0
An undetermined value
Char array cannot be printed directly using printf
Array is not a left value and so cannot be assigned to
Program compiles without error, but prints an unpredictable value
Array cannot be initialized as above
0
Compiler dependent
1
-1
Wait!
Here's an interesting quiz for you.