Test your basic knowledge |

C++ Programming Basics

Subject : it-skills
Instructions:
  • Answer 50 questions in 15 minutes.
  • If you are not ready to take this test, you can study here.
  • Match each statement with the correct term.
  • Don't refresh. All questions and answers are randomly picked and ordered every time you load a test.

This is a study tool. The 3 wrong answers for each question are randomly chosen from answers to other questions. So, you might find at times the answers obvious, but you will see it re-enforces your understanding as you take the test each time.
1. A function is invoked with a ________.






2. Variables declared in a block or in the parameter list of a function are assumed to be of storage class ________ unless specified otherwise.






3. The number used to refer to a particular element of an array is called its ________.






4. Class members specified as _________ are accessible only to member functions of the class and friends of the class.






5. Initializers __________ must be used to initialize constant members of a class.






6. A C++ statement that makes a decision is ______.






7. Creates a copy of a string.






8. The stream insertion operator






9. Preprocessor directive syntax






10. To allow file access in a program you must #include this header file.






11. Used for dynamically allocated variables






12. The _________ begins the body of every function and the _________ ends the body of every function.






13. A sequence of operands and operators that describe a calculation to be performed






14. The storage-class specifiers are mutable - auto - ________ - extern and static.






15. Class members are accessed via the ________ operator in conjunction with the name of an object (or reference to an object) of the class or via the arrow (->) operator in conjunction with a pointer to an object of the class.






16. Naming convention for C++ programs






17. A __________ data member represents class-wide information.






18. The conditional operator. it evaluates a line of code and returns one thing if the condition is true and a different thing if the condition is false.






19. These are data items whose values do not change while the program is running






20. The four areas that a program uses memory on are: the codes area - the _______ area - the stack and the heap.






21. Function ________ is used to set the random number seed to randomize a program.






22. Classes can have relationships with other classes. These relationships are called ________.






23. When you create a ___________________in the base class and then call it using an object the function will know to look in the inherited class for the specifics of that function.






24. Words that are used for special purposes in a program






25. You can reassign the operator features in C++ to do things other than what they would do naturally. This is called ____________






26. A variable that is known only within the function in which it is defined is called a ________.






27. Header file that contains commonly performed mathematical functions






28. The size & shape & color and weight of an object are considered






29. The source-code file and any other files that use a class can include the class's header file via an _________ preprocessor directive.






30. A memory location with a name and data type - its content may be changed during program execution






31. C++ programmers concentrate on creating ________ which contain data members and the member functions that manipulate those data members and provide services to clients.






32. Returns the length of a string excluding the null terminator.






33. This is used to mark the end of a complete C++ programming statement.






34. A file must be ________ before data can be written to or read from it.






35. All ______ must be declared before they are used.






36. A variable that holds the address of another variable.






37. The modulus operator (%) can be used only with __________.






38. Function ________ is used to produce random numbers.






39. You can declare default values for a function in the ____________________.






40. A set of values together with a set of operations






41. A function that can be used to read character data including whitespace






42. directive A statement that starts with a # is called a ____________.






43. The process of analyzing and designing a system from an object-oriented point of view is called ________.






44. Compares two strings and returns 0 if they are equal.






45. In inheritance the ____________ is the class that supplies the inherited members.






46. A pointer is a variable that contains as its value the____________ of another variable.






47. Sets floating-point values to a fixed decimal format






48. Operator with only one operand






49. To write data to a file you define an object of which one of the following






50. The keyword __________ specifies that an object or variable is not modifiable after it is initialized.







Sorry!:) No result found.

Can you answer 50 questions in 15 minutes?


Let me suggest you:



Major Subjects



Tests & Exams


AP
CLEP
DSST
GRE
SAT
GMAT

Most popular tests