Programming for Problem Solving (3110003) MCQs

MCQs of Fundamentals of C

Showing 41 to 50 out of 107 Questions
41.
A declaration float sum, value; occupies _____ of memory?
(a) 2 byte
(b) 4 byte
(c) 6 byte
(d) 8 byte
Answer:

Option (d)

42.
MACRO is used to _______________.
(a) Save memory
(b) fast execution
(c) Both a & b
(d) none of above
Answer:

Option (b)

43.

Which of the following is a symbol for logical AND operator?

(a)

II

(b)

&

(c)

&&

(d)

$$

Answer:

Option (c)

44.
What will be the output of following program

#include

main()

{

        int x,y = 10;

        x = y * NULL;

        printf(\"%d\",x);

}

(a) error
(b) 0
(c) 10
(d) garbage value
Answer:

Option (a)

45.
printf() belongs to which library of c
(a) stdlib.h
(b) stdio.h
(c) stdout.h
(d) stdoutput.h
Answer:

Option (b)

46.
What will be printed if we type the statement printf(“%d\n”,’d’);
(a) 0
(b) 100
(c) error
(d) d
Answer:

Option (b)

47.
C is a __________ language
(a) High level
(b) Middle level
(c) Machine level
(d) Low level
Answer:

Option (b)

48.
Which of the following function is more appropriate for reading in a multiword string?
(a) printf();
(b) scanf();
(c) gets();
(d) puts();
Answer:

Option (c)

49.
What are the different types of real data types in C?
(a) float, double
(b) short int, double, long int
(c) double, long int, float
(d) float, double, long double
Answer:

Option (d)

50.
Which of the following is a correct statement?
(a) Variable name must start with underscore
(b) Variable name must have digit
(c) Variable name must have white space character
(d) Keyword cannot be a variable name
Answer:

Option (d)

Showing 41 to 50 out of 107 Questions