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. Executable version of program






2. C++ programmers concentrate on creating ________ which contain data members and the member functions that manipulate those data members and provide services to clients.






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






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






5. Use 2 characters to represent one






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






7. Function _________ from the <string> library reads characters until a newline character is encountered - then copies those characters into the specified string.






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






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






10. Type casting syntax






11. data types that refer to numbers with decimals






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






13. The process of analyzing and designing a system from an object-oriented point of view is called ________.






14. tab






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






16. Used for dynamically allocated variables






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






18. * / % + -






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






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






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






22. A filestream variable that represents the default input source






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






24. Syntax for named constant declaration






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






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






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






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






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






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






31. An expression that has operands with different data types






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






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






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






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






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






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






38. An operator that can only be used with int values. result will always be an int.






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






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






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






42. A C++ statement that makes a decision is ______.






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






44. A pointer is a variable that contains as its value the____________ of another variable.






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






46. Associate an identifier with a memory location






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






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






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






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