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. A program that finds and attaches to your program the indicated libraries for compilation






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






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






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






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






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






7. Naming convention for C++ programs






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






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






10. The sign you use for references






11. data types that refer to numbers with decimals






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






13. Return type _________ indicates that a function will perform a task but will not return any information when it completes its task.






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






15. The conditional operator. it evaluates a line of code and returns one thing if the condition is true and a different thing if the condition is false.






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






17. A________ allows the compiler to check the number & types and order of the arguments passed to a function.






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






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






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






21. You can reassign the operator features in C++ to do things other than what they would do naturally. This is called ____________






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






23. Operator with only one operand






24. A function that calls itself either directly or indirectly - through another function) - is a ________ function.






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






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






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






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






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






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






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






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






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






34. Syntax for named constant declaration






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






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






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






38. Preprocessor directive syntax






39. Nonexecutable statements that are included in a program to provide information about what the program does etc.






40. Keyword public is a(n) _________






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






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






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






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






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






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






47. A filestream variable that represents the default output device






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






49. The ________ qualifier is used to declare read-only variables.






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