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. Grammar rules of the language; compiler will try to identify and locate syntax errors






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






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






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






5. A filestream variable that represents the default output device






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






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






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






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






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






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






12. The address-of operator. it is used to assign pointers and to print the address of variables.






13. newline






14. tab






15. A file must be ________ before data can be written to or read from it.






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






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






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






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






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






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






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






23. Preprocessor directive syntax






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






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






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






27. data types that refer to numbers with decimals






28. When a value of one data type is implicitly (automatically) changed to another data type






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






30. All C++ Variables are_________.






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






32. All ______ must be declared before they are used.






33. A ________ program executes before the compiler's translation phase begins.






34. Executable version of program






35. A memory location with a name and data type and a value - its content (value) cannot be changed during program execution






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






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






38. Header file that contains commonly performed mathematical functions






39. The six possible scopes of an identifier are ________ - file scope - block scope - function-prototype scope - class scope - namespace scope .






40. A member function should be declared static if it does not access __________ class members.






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






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






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






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






45. Used for function calls and local variables






46. Syntax for named constant declaration






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






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






49. Compares two strings and returns 0 if they are equal.






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