Object Oriented Programming (OOPs) MCQs > FREE SET - 1

1. The delete operator returns _________ to the operating system.
A memory that is no longer needed
B void
C recycle bin
D None of the above

Free MCQs www.sharemcq.com     Answer: Option A
Explanation:
Available Soon.

2. The major advantage of data hiding is that __________.
A your programs can include more data
B you no longer need functions
C no one can ever use your data
D your data will be used correctly

Free MCQs www.sharemcq.com     Answer: Option D
Explanation:
Available Soon.

3. The letter
A character literal constant
B numeric literal constant
C string literal constant
D variable

Free MCQs www.sharemcq.com     Answer: Option A
Explanation:
Available Soon.

4. Separating parts of a program into units that remain unaffected by other parts of a program is the concept known as __________.
A intrusion
B volatility
C encapsulation
D protection

Free MCQs www.sharemcq.com     Answer: Option C
Explanation:
Available Soon.

5. A function whose purpose is to send messages to other functions is known as a _________.
A dispatcher
B courier
C messenger
D sender

Free MCQs www.sharemcq.com     Answer: Option A
Explanation:
Available Soon.

6. With commercial classes, the function source code is usually___________.
A printed on high-quality paper
B poorly written
C provided on a disk
D provided in object form

Free MCQs www.sharemcq.com     Answer: Option D
Explanation:
Available Soon.

7. The type of value that a function sends back to the function that calls it is known as its __________.
A type
B return value
C reference data
D sentinel

Free MCQs www.sharemcq.com     Answer: Option B
Explanation:
Available Soon.

8. Which of the following are never inherited?
A public data members
B constructor functions
C void functions
D overloaded + operators

Free MCQs www.sharemcq.com     Answer: Option B
Explanation:
Available Soon.

9. The expression c = i++ causes
A the value of i assigned to c and then i incremented by 1
B i to be incremented by 1 and then the value of i assigned to c
C value of i assigned to c
D i to be incremented by 1

Free MCQs www.sharemcq.com     Answer: Option A
Explanation:
Available Soon.

10. An identifier in C
A is a name of a thing such as variable and function
B is made up of letters, numerals, and the underscore
C can contain both uppercase and lowercase letters
D All of the above

Free MCQs www.sharemcq.com     Answer: Option D
Explanation:
Available Soon.

11. Which of the following creates a String named constant called partNo, whose value is AB25?
A const char[4] partNo = "AB25";
B const char[5] partNo = 'AB25';
C const char[5] partNo = "AB25";
D const char partNo[5] = "AB25";

Free MCQs www.sharemcq.com     Answer: Option D
Explanation:
Available Soon.

12. The bitwise AND operator is represented by the symbol
A ^
B &
C &&
D >>

Free MCQs www.sharemcq.com     Answer: Option B
Explanation:
Available Soon.

13. The exclusive OR operator gives the result 1 when
A both the bits are 0
B one bit is 0 and the other is 1
C both the bits are 1
D no hard and fast rule

Free MCQs www.sharemcq.com     Answer: Option B
Explanation:
Available Soon.

14. The function strcmp("India", "INDIA") will return ________.
A India
B INDIA
C 0
D 1

Free MCQs www.sharemcq.com     Answer: Option D
Explanation:
Available Soon.

15. Which of the following is the extraction operator?
A >>
B <<
C //
D /*

Free MCQs www.sharemcq.com     Answer: Option A
Explanation:
Available Soon.

16. When a multidimensional array is accessed, each array index is
A separated by commas
B surrounded by brackets and separated by commas
C separated by commas and surrounded by brackets
D surrounded by brackets

Free MCQs www.sharemcq.com     Answer: Option D
Explanation:
Available Soon.

17. To create a variable, you must assign _________ to it.
A a data type
B a name
C both a data type and a name
D the word var

Free MCQs www.sharemcq.com     Answer: Option C
Explanation:
Available Soon.

18. You indicate that a variable is a pointer variable by placing a(n) _________ in front of the variable's name.
A asterisk
B ampersand
C dollar sign
D exclamation point

Free MCQs www.sharemcq.com     Answer: Option A
Explanation:
Available Soon.

19. A function can make_________.
A one throw
B one throw of each scalar type
C one throw of each programmer-defined type
D as many throws of as many types as necessary

Free MCQs www.sharemcq.com     Answer: Option D
Explanation:
Available Soon.

20. A default exception block must be placed ___________.
A first among the catch blocks
B last among the catch blocks
C globally, at the top of the file
D at the end of all code in the program

Free MCQs www.sharemcq.com     Answer: Option B
Explanation:
Available Soon.

21. Which of the following control structures is used in every program?
A repetition
B selection
C sequence
D switching

Free MCQs www.sharemcq.com     Answer: Option C
Explanation:
Available Soon.

22. In the C language, a string is assigned to the
A char type of variable
B string type of variable
C conversion specification %s
D All of the above

Free MCQs www.sharemcq.com     Answer: Option A
Explanation:
Available Soon.

23. Which of the following statements declares a one-dimensional Character array named item that consists of five elements?
A char item[0 to 4] = "";
B char item[0 to 5] = "";
C char item[4] = "";
D char item[5] = "";

Free MCQs www.sharemcq.com     Answer: Option D
Explanation:
Available Soon.

24. The main() function is always
A a called function
B a calling function
C recursive function
D used at the end of the program

Free MCQs www.sharemcq.com     Answer: Option B
Explanation:
Available Soon.

25. Variables that are known only to the function in which they are declared are called __________ variables.
A global
B local
C main
D separate

Free MCQs www.sharemcq.com     Answer: Option B
Explanation:
Available Soon.

26. In the expression p --> val, p is a(n)
A address
B pointer
C structure
D header

Free MCQs www.sharemcq.com     Answer: Option B
Explanation:
Available Soon.

27. In a template function, __________ argument is generic, or parameterized.
A no
B exactly one
C at least one
D more than one

Free MCQs www.sharemcq.com     Answer: Option C
Explanation:
Available Soon.

28. Object-oriented programmers primarily focus on _________.
A procedures to be performed
B the step-by-step statements needed to solve a problem
C objects and the tasks that must be performed with those objects
D the physical orientation of objects within a program

Free MCQs www.sharemcq.com     Answer: Option C
Explanation:
Available Soon.

29. The standard output stream, which refers to the computer screen, is called
A cin
B cout
C stin
D stout

Free MCQs www.sharemcq.com     Answer: Option B
Explanation:
Available Soon.

30. Which of the following operators is the equality operator?
A !=
B =
C ==
D ->>

Free MCQs www.sharemcq.com     Answer: Option C
Explanation:
Available Soon.

31. In C++, you use _________ to perform standard input and output operations.
A characters
B sequences
C streams
D tests

Free MCQs www.sharemcq.com     Answer: Option C
Explanation:
Available Soon.

32. Values that are used to end loops are referred to as ________ values.
A end
B finish
C sentinel
D stop

Free MCQs www.sharemcq.com     Answer: Option C
Explanation:
Available Soon.

33. Which of the following flowchart symbols represents the if selection structure?
A diamond
B hexagon
C oval
D parallelogram

Free MCQs www.sharemcq.com     Answer: Option A
Explanation:
Available Soon.

34. Two or more arrays whose elements are related by their position (subscript) in the arrays are called __________ arrays.
A horizontal
B paired
C parallel
D related

Free MCQs www.sharemcq.com     Answer: Option C
Explanation:
Available Soon.

35. Assume that a program creates and initializes a Short Integer variable named age and a pointer named agePtr, to which it assigns the address of the age variable. Which of the following statements will assign the number 21 to the age variable?
A age = 21;
B *age = 21;
C *agePtr = 21;
D both (A) and (C)

Free MCQs www.sharemcq.com     Answer: Option D
Explanation:
Available Soon.

36. The body of a C++ function is surrounded by __________.
A parentheses
B angle brackets
C curly brackets
D square brackets

Free MCQs www.sharemcq.com     Answer: Option C
Explanation:
Available Soon.

37. Which of the following type casts will convert an Integer variable named amount to a Double type?
A (double) amount
B (int to double) amount
C int to double(amount)
D int (amount) to double

Free MCQs www.sharemcq.com     Answer: Option A
Explanation:
Available Soon.

38. The loosest type of coupling is
A data coupling
B control coupling
C external coupling
D pathological coupling

Free MCQs www.sharemcq.com     Answer: Option A
Explanation:
Available Soon.

39. A child class _________ exist if there is no parent class.
A must
B may
C cannot
D can

Free MCQs www.sharemcq.com     Answer: Option C
Explanation:
Available Soon.

40. Which of the following is not an Object Oriented Programming Language?
A Python
B PASCAL
C Java
D C++

Free MCQs www.sharemcq.com     Answer: Option B
Explanation:
Available Soon.

41. Which of the following languages is a mathematically oriented language for scientific problems?
A LISLP
B PROLOG
C FORTRAN
D COBOL

Free MCQs www.sharemcq.com     Answer: Option C
Explanation:
Available Soon.

42. Which of the following is a scripting language, running on the server, which can be used to create web pages.
A Javascript
B PHP
C Android
D VB Script

Free MCQs www.sharemcq.com     Answer: Option B
Explanation:
Available Soon.

43. Which of the following is not a DBMS?
A SQL SERVER
B ORACLE DB
C MYSQL
D None of the above

Free MCQs www.sharemcq.com     Answer: Option D
Explanation:
Available Soon.

44. Which of the following is not an Object Oriented Programming Language?
A C++
B JAVA
C FORTRAN
D Python

Free MCQs www.sharemcq.com     Answer: Option C
Explanation:
Available Soon.

45. Which of the following is true about Assembly Language?
A It is High-level programming language
B It is low-level programming language
C It is Machine Language
D It is language for assembling computers

Free MCQs www.sharemcq.com     Answer: Option B
Explanation:
Available Soon.

46. Who is said to be the first computer programmer?
A Charles Babbage
B John Mauchly
C Ada Lovelace
D Douglas Engelbart

Free MCQs www.sharemcq.com nbsp;    Answer: Option C
Explanation:
Available Soon.

47. Which of the following is a programming language?
A Pascal
B Lotus
C Netscape
D MS-Excel

Free MCQs www.sharemcq.com     Answer: Option A
Explanation:
Available Soon.

48. A NAND gate is formed by ________?
A An AND gate followed by an OR gate
B An NOT gate followed by an AND gate
C An AND gate followed by NOT gate
D An OR gate followed by an AND gate

Free MCQs www.sharemcq.com     Answer: Option C
Explanation:
Available Soon.

49. The first computers were programmed using
A Assembly language
B Machine language
C Object code
D Source code

Free MCQs www.sharemcq.com     Answer: Option B
Explanation:
Available Soon.

50. MySQL is
A A hierarchical model
B A relational model
C A RDBMS
D A database scheme

Free MCQs www.sharemcq.com     Answer: Option C
Explanation:
Available Soon.


No comments:

Post a Comment

Your Feedback is hearty Requested to make the MCQs Collection better.

Popular Posts