Question with Answer MCA

1. The following program fragment,  if (a = 0) printf (“a is zero”) ;  else printf (“a is not zero”) ; results in the printing of
(a) a is zero 
(b) a is not zero 
(c) noting
(d) garbage
Ans. c
 
2. If y is of integer type, then the expressions 3*(y – 8) / 9 and (y – 8) / * 3  yield the same value, if
(a) y is an even number
(b) y is an odd number
(c) y-8 is an integral multiple of 9
(d) y-8 is an integral multiple of 3
Ans. c

3. The base of the binary number system is
(a) 2
(b) 16
(c) 8
(d) 10
Ans. a
 
4. Main memory unit of computer
(a) performs arithmetic
(b) stores a small amount of data and instructions
(c) stores bulk of data and instructions
(d) supervises the working of all the units
Ans. b
 
5. A Central Processing Unit (CPU) consist of
(a) input, output unit
(b) memory unit
(c) arithmetic and logical unit, central unit
(d) keyboard, printer
Ans. c

6. If the integer needs two bytes of storage, then maximum value of an unsigned integer is
(a) 216 – 1
(b) 215 – 1
(c) 216
(d) 215
Ans. a
 
7. The minimum number of temporary variables needed to swap the contents of two variables is
(a) 1
(b) 2
(c) 3
(d) 0
Ans. a
 
8. Which is true of conditional compilation?
(a) It is taken care of by the compiler
(b) It is setting the compiler option conditionally
(c) It is compiling a program based on a condition
(d) It is operation taken by the compiler
Ans. c
 
9. The basic arithmetic operation performed by a computer is
(a) addition
(b) mulitiplication
(c) subtraction
(d) division
Ans. a

10. The southernmost point of Indian territory is in which of the following States/Union Territories?
(a) Tamil Nadu
(b) Lakshadweep
(c) Kerela
(d) Andaman and Nicobar Islands
Ans. d

For More Question with Answer MCA - Click Here