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 stream insertion operator






2. A type of pointer that can point at objects of any data type.






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






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






5. Used for function calls and local variables






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






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






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






9. newline






10. The stream extraction operator






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






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






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






14. tab






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






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






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






18. Preprocessor directive syntax






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






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






21. To explicitly indicate that a value is to be converted to another type






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






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






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






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






26. The keyword __________ specifies that an object or variable is not modifiable after it is initialized.






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






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






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






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






31. The __________ operator reclaims memory previously allocated by new.






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






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






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






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






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






37. When it is not known in advance how many times a set of statements will be repeated a _________value can be used to terminate the repetition.






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






39. An expression that has operands with different data types






40. The sign you use for references






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






42. Function ________ is used to produce random numbers.






43. * / % + -






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






45. Manipulator that causes the insertion point (cursor) to move to the beginning of the next line

Warning: Invalid argument supplied for foreach() in /var/www/html/basicversity.com/show_quiz.php on line 183


46. The elements of an array are related by the fact that they have the same name and ___________.






47. data types that refer to numbers with decimals






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






49. Can be used as a compound "if" statement. it includes a number of different possibilities and directions rather than a single test.






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