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 file must be ________ before data can be written to or read from it.






2. Symbol that denotes an action to be performed






3. A human readable file that contains C++ program






4. The ________ statement in a called function passes the value of an expression back to the calling function.






5. Preprocessor directive syntax






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






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






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






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






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






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






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






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






14. The sign you use for references






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






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






17. Grammar rules of the language; compiler will try to identify and locate syntax errors






18. Keyword public is a(n) _________






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






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






21. A filestream variable that represents the default output device






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






23. The three ways to return control from a called function to a caller are ________ - return expression and encounter.






24. int namespace include using return examples of ___________






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






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






27. The_________selection statement is used to execute one action when a condition is TRue or a different action when that condition is false.






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






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






30. Repeating a set of instructions a specific number of times is called_________repetition.






31. A function is invoked with a ________.






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






33. The _____ causes the contents of another file to be inserted into a program.






34. Most calculations are normally performed by ______ statements.






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






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






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






38. Type casting syntax






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






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






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






42. A________ allows the compiler to check the number & types and order of the arguments passed to a function.






43. All C++ Variables are_________.






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






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






46. Default name of executable file






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






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






49. Associate an identifier with a memory location






50. The process of determining if an array contains a particular key value is called _________ the array.