MCQ Bank
Which of the following expression is correct in C/C++ language?
- A) X=X+3
- B)
- C)
- D)
Which of the following C++ statement is used to take input from the user?
- A) cin
- B)
- C)
- D)
Which of the following is an example of logical operator?
- A) &&, ||
- B)
- C)
- D)
in C/C++, which of the following data type is used to store real numbers?
- A) Float
- B)
- C)
- D)
C/C++ has many libraries which contain variables and function names normally starting with ________
- A) Underscore
- B)
- C)
- D)
The coding of a program is translated into machine language by ________
- A) Compiler
- B)
- C)
- D)
Learning "How to program" is important, because it develops ________ and problem solving abilities.
- A) Analytical
- B)
- C)
- D)
in C/C++, the algebraic expression (b2-4ac)/2a can be written as:
- A) (b*b-4*a*c)/(2*a)
- B)
- C)
- D)
In C/C++, which of the following data type is used to store real member?
- A) Float
- B)
- C)
- D)
To understand programming concepts, ________ programming language being used as a vehicle in cs201 "Introduction to programming" course.
- A) C/C++
- B)
- C)
- D)
The bit manipulators operator ________ is used to check whether a specific bit is set or not.
- A) &
- B)
- C)
- D)
in C++, which operator is used while accessing through the pointer to structure?
- A) ->
- B)
- C)
- D)
Function seekg() and seekp() require an argument of type ________ to let them know how many bytes to move forward backward.
- A) Long
- B)
- C)
- D)
Macro is defined by ________ preprocessor directive.
- A) #define
- B)
- C)
- D)
In C++, when accessing files randomly, which function is used to get current pointer position inside a file?
- A) tellg()
- B)
- C)
- D)
Which is not a preprocessor directive of C-Language?
- A) # Startif
- B)
- C)
- D)
The statement char arr[10]; is an example of a type of ________ memory allocation
- A) static
- B)
- C)
- D)
What would be the output of the following statement? C=13%2;
- A) 1
- B)
- C)
- D)
Which of the following two array are copy-able?
- A) int a[5], int b[5]
- B)
- C)
- D)
A variable declared inside a code block becomes the ________ variable for that block.
- A) Local
- B)
- C)
- D)