DG

dhirendra_gupta

Student at BIT Mesra Aug. 23, 2020, 12:55 p.m. ⋅ 118 views

Placement preparation C Programming Objective Type Questions with answers (Set 2)


Q1. Functions with same name and different parameters represents :

a) function overloading

b) function overriding

c) recursion

d) None of the mentioned

ANSWER:(a)

 

Q2. getch() is present in this header file

a) stdio.h

b) conio.h

c) stdlib.h

d) None of the mentioned

ANSWER: (b)

 

Q3. This keyword is used for defining new data type names.

a) docstring

b) typedef

c) Both of them

d) None of them

ANSWER: (b)


Q4. Which precision specifier the number of significant digits ?

a) %g

b) %G

c) %f

d) Both a and b

ANSWER: (d)


Q5. In order to display address, we need :

a) %q

b) %a

c) %p

d) None of the mentioned

ANSWER: (c)

 

Q6. _____ is used to take user input in C.

a) input()

b) printf()

c) scanf()

d) None of the above

ANSWER: (c)

 

Q7. ‘%[ ]’ is used for :

a) taking array as input

b) scans for set of characters

c) takes integer as input

d) None of the above

ANSWER: (b)

 

Q8. To avoid repetition of code and bulky programs, statements are isolated inside a _____.

a) Functions
b) Modules
c) Header Files
d) None of the above

ANSWER: (a)


 
Q9. In C, order of passing arguments to a function is done : 

a) left to right

b) right to left

c) Randomly

d) Manually

ANSWER: (b)

 

Q10. pow() is present in which header file ?

a) maths.h

b) arithmetic.h

c) process.h

d) math.h

ANSWER: (d)

 

Q11. In pointers, meaning of ‘*’ is :

a) pointer variable

b) value at address

c) value of address

d) None of the mentioned

ANSWER: (b)

 

Q12. When double is converted to float then the value is ?

a) Truncated

b) Rounded

c) Depends upon compiler

d) None of the mentioned

ANSWER: (c)


 
Q13. Can we declare function inside structure of C ?

a) YES

b) NO

c) Both of them

d) None of them

ANSWER: (b)

 

Q14. Which of the following is an ternary operator in C?

a) &&

b) %%

c) !=

d) ?:

ANSWER: (d)


Q15. What is the use of ‘%%’ specifier ?

a) Finding remainder

b) Finding quotient

c) Printing % sign

d) None of the mentioned

ANSWER: (c)



Go back to feed

HackersFriend Updates





View more


Events


Nov. 28, 2018, 5:30 p.m.

Python from zero to hero

place Delhi

View details


Aug. 13, 2018, 5:30 p.m.

Python from zero to hero

place Bangalore ( HackersFriend office BTM Layout)

View details