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 that calls itself either directly or indirectly - through another function) - is a ________ function.






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






3. If a member initializer is not provided for a member object of a class the object's __________ is called.






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






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






6. This happens when too much memory is pushed onto the stack and overflows to other areas of memory.






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






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






9. A filestream variable that represents the default input source






10. Two slash marks ( // ) indicate __________ of a comment






11. Operator with only one operand






12. Used for dynamically allocated variables






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






14. Syntax for named constant declaration






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






16. The ________ of an identifier is the portion of the program in which the identifier can be used.






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






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






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






20. The escape sequence ___ when output with cout and the stream insertion operator - causes the cursor to position to the beginning of the next line on the screen.






21. Member objects are constructed __________ their enclosing class object.






22. Causes the program exits the loop - skipping over the rest of the commands and starts executing again with the next thing outside the loop.






23. The escape sequence n represents the _________ character which causes the cursor to position to the beginning of the next line on the screen.






24. __________ can be used to assign an object of a class to another object of the same class.






25. Meaning of the instructions in the language; compiler cannot find these errors - often called logic errors






26. The only integer that can be assigned directly to a pointer is_____________.






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






28. A function that calls itself






29. Identifier or expression that is part of the calculation to be performed






30. The ________ program combines the output of the compiler with various library functions to produce an executable image.






31. You must have a ___________ for every variable you intend to use in a program






32. The ________ program transfers the executable image of a C++ program from disk to memory.






33. Characters used to separate symbols or reserved words or identifiers and statements






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






35. tab






36. The ________ qualifier is used to declare read-only variables.






37. int namespace include using return examples of ___________






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






39. Can be used as a compound "if" statement. it includes a number of different possibilities and directions rather than a single test.






40. The symbol for the binary scope resolution operator






41. Operator with two operands






42. Program components in C++ are called functions and ________.






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






44. The sign you use for pointers






45. The stream insertion operator






46. When it is not known in advance how many times a set of statements will be repeated a _________value can be used to terminate the repetition.






47. The stream extraction operator






48. Used to qualify hidden names so that they can be used.






49. Keyword public is a(n) _________






50. Every C++ statement ends with a(n) _________.