C Question Bank
C Question Bank
43. Which pair of functions below are used for single character I/O.
a) Getchar() and putchar()
b) Scanf() and printf()
c) Input() and output()
d) None of these
Ans: a
44. The printf() function retunes which value when an error occurs?
a) Positive value
b) Zero
c) Negative value
d) None of these
Ans: c
45. Identify the wrong statement
a) putchar(65)
b) putchar(‘x’)
c) putchar(“x”)
d) putchar(‘\n’)
Ans: c
SAMARTH COMPUTER INSTITUTE
46. Which of the following is charecter oriented console I/O function?
a) getchar() and putchar()
b) gets() and puts()
c) scanf() and printf()
d) fgets() and fputs()
Ans: a
47. The output of printf(“%u”, -1) is
a) -1
b) minimum int value
c) maxium int value
d) Error message
Ans: c
48. An Ampersand before the name of a variable denotes
a) Actual Value
b) Variable Name
c) Address
d) Data Type
Ans: c