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. The escape sequence n represents the _________ character which causes the cursor to position to the beginning of the next line on the screen.






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






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






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






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






6. Used for function calls and local variables






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






8. Names of things that are used in a program - can apply to variables & constants and functions






9. tab






10. A function that calls itself






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






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






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






14. Syntax for named constant declaration






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






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






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






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






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






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






21. All C++ Variables are_________.






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






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






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






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






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






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






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






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






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






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






32. An array that uses two subscripts is referred to as a(n) _________ array.






33. Forces the computer to display decimal point and trailing zeroes






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






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






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






37. Smallest individual unit of a programming language - special symbols or word symbols or identifiers






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






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






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






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






42. Naming convention for C++ programs






43. Symbol that denotes an action to be performed






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






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






46. A function is invoked with a ________.






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






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






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






50. An expression that has operands with different data types