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. Smallest individual unit of a programming language - special symbols or word symbols or identifiers






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






3. Used for function calls and local variables






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






5. The stream insertion operator






6. Default name of executable file






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






8. For every opening brace in a C++ program there must be a ______________.






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






10. Class members specified as _________ are accessible anywhere an object of the class is in scope.






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






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






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






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






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






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






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






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






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






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






21. It is possible to have various functions with the same name that operate on different types or numbers of arguments. This is called function ________.






22. Allows the programmer to store a value in a variable






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






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






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






26. An object's non-static member functions have access to a "self pointer" to the object called the __________ pointer.






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. Single letters or digits or special symbols; enclose value in single quotes ('a' '?' '8')






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






30. Creates a copy of a string.






31. Causes the program to immediately goes back to the top of the loop. the remainder of the statements in the loop are ignored for this current iteration.






32. int namespace include using return examples of ___________






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






34. Used for dynamically allocated variables






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






36. Keyword public is a(n) _________






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






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






39. Every C++ program begins execution at the function _________.






40. data types that refer to numbers with decimals






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






42. A function is invoked with a ________.






43. Syntax for reading char type variables by extracting one nonwhitespace character extracted at a time






44. The stream extraction operator






45. A __________ should be used to declare the size of an array because it makes the program more scalable.






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






47. Preprocessor directive syntax






48. Storage-class specifier ________ is a recommendation to the compiler to store a variable in one of the computer's registers.






49. = & | are examples of ____________.






50. Message displayed to the screen asking user for input; generated with an output statement