Programming for Problem Solving (3110003) MCQs

MCQs of Fundamentals of C

Showing 61 to 70 out of 107 Questions
61.
Which symbol ends a statement in C program?
(a) . (full stop)
(b) ; (semicolon)
(c) : (colon)
(d) } (curly braces)
Answer:

Option (b)

62.
Which symbol is used to comment single statement?
(a) //
(b) \\
(c) /*
(d) \*
Answer:

Option (a)

63.
Why preprocessor directive needed in the beginning of a C program?
(a) To start execution of a program
(b) To include keywords in a program
(c) To include files in a program
(d) None of these
Answer:

Option (c)

64.
Header file is compulsory to include in a C program printing “Hello World”
(a) True
(b) False
Answer:

Option (a)

65.
Which of the following is not a basic data type in C language?
(a) float
(b) int
(c) real
(d) char
Answer:

Option (c)

66.
How many keywords are there in C?
(a) 31
(b) 32
(c) 64
(d) 63
Answer:

Option (b)

67.
Which of the following is true for variable names in C?
(a) Variable names cannot start with a digit
(b) Variable can be of any length
(c) They can contain alphanumeric characters as well as special characters
(d) Reserved word can be used as a variable name
Answer:

Option (a)

68.
Character literal in C syntax is?
(a) Z
(b) ‘Z’
(c) “Z”
(d) None of these
Answer:

Option (b)

69.
Choose the correct statement about C escape sequences
(a) \n produces a new line
(b) \t produces one tab space (white spaces)
(c) \b produces one backspace
(d) All of these
Answer:

Option (d)

70.
Choose a valid C format specifier
(a) %d prints integer constants
(b) %f prints float constants
(c) %c prints character constants
(d) All of these
Answer:

Option (d)

Showing 61 to 70 out of 107 Questions