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. Every C++ program begins execution at the function _________.






2. Used for dynamically allocated variables






3. Manipulator that causes the insertion point (cursor) to move to the beginning of the next line

Warning: Invalid argument supplied for foreach() in /var/www/html/basicversity.com/show_quiz.php on line 183


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






5. This manipulator is used to establish a field width for the value immediately following it.






6. A function that calls itself either directly or indirectly - through another function) - is a ________ function.






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






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






9. Objects have the property of ________although objects may know how to communicate with one another across well-defined interfaces - they normally are not allowed to know how other objects are implemented.






10. A nonmember function must be declared as a(n) __________ of a class to have access to that class's private data members.






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






12. The new operator dynamically allocates memory for an object of a specified type and returns a __________ to that type.






13. The symbol for the binary scope resolution operator






14. The three values that can be used to initialize a pointer are 0 - __________ and an address.






15. When the compiler sees this keyword the function call is replaced with a copy of the contents of the function itself.






16. A function ________ enables a single function to be defined to perform a task on many different data types.






17. Naming convention for C++ programs






18. The ________ enables access to a global variable with the same name as a variable in the current scope.






19. This allows the writer to create functions of the same name as long as they have different parameters or different quantities of parameters.






20. Lists and tables of values can be stored in arrays or __________.






21. The stream insertion operator






22. The keyword ________ is used in a function header to indicate that a function does not return a value or to indicate that a function contains no parameters.






23. Comments do not cause the computer to print the text after the____ on the screen when the program is executed.






24. A recursive function typically has two components: One that provides a means for the recursion to terminate by testing for a(n) ________ case and one that expresses the problem as a recursive call for a slightly simpler problem than the original call






25. The sign you use for pointers






26. Creates a copy of a string.






27. The stream extraction operator






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






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






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






31. C++ programs are normally typed into a computer using a(n) ________ program.






32. For a local variable in a function to retain its value between calls to the function it must be declared with the ________ storage-class specifier.






33. Use 2 characters to represent one






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






35. Most calculations are normally performed by ______ statements.






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






37. Syntax for named constant declaration






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






39. All programs can be written in terms of three types of control structures:Sequence - ________and Repetition.






40. An expression in which all operands have the same data type - result will have the same data type as operands






41. Preprocessor directive syntax






42. OOD also takes advantage of ________ relationships where new classes of objects are derived by absorbing characteristics of existing classes - then adding unique characteristics of their own.






43. ________ is a graphical language that allows people who design software systems to use an industry-standard notation to represent them.






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






45. A constant object must be __________; it cannot be modified after it is created.






46. 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.






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






48. In inheritance the ____________ is the class the receives the inherited members.






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






50. The process of placing the elements of an array in order is called ________ the array.