GkSeries.com

C programming short Questions with Answers

(41) Choose the option that contains only valid hexadecimal integers.
[A] 0x9F, 0xbcd, 0x1
[B] 037, 00x, 01000
[C] 0x561u, 0x9h, 0xdd
[D] H9F, HFF, HAA

Comment

Answer: Option [D]

The base of Hexadecimal number system is 16. It contains 0 to 9 and A,B,C.D,E,F to represent zero to fifteen.

(42) Which of the following is not valid variable names in 'C'?
[A] float_int, keyword, A1
[B] ANSI, ascii, cpu
[C] valid, variable, name
[D] None of these

Comment

Answer: Option [D]

DOWNLOAD CURRENT AFFAIRS PDF FROM APP

(43) The result of a relational operator is always
[A] either True or False
[B] is less than or is more than
[C] is equal or less or more
[D] All of these

Comment

Answer: Option [A]

The relational operators in 'C' are ==, !=, >, <, >=, <=. They always results in either True or False.

(44) Which of the following cannot be used as identifiers?
[A] Letters
[B] Digits
[C] Underscores
[D] Spaces

Comment

Answer: Option [D]

Variable name, function name, structure name etc. are called identifiers. Spaces are not used in names.

(45) What is the return type of ftell function?
[A] double
[B] int
[C] long
[D] float

Comment

Answer: Option [C]

Please share this page

Chapters

Click Here to Read more questions

Teacher Eligibility Test