SUBJECTS
|
BROWSE
|
CAREER CENTER
|
POPULAR
|
JOIN
|
LOGIN
Business Skills
|
Soft Skills
|
Basic Literacy
|
Certifications
About
|
Help
|
Privacy
|
Terms
|
Email
Search
Test your basic knowledge |
C++ Programming Basics
Start Test
Study First
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. These are data items whose values do not change while the program is running
semantics
heap
Literals
main
2. A function that calls itself
type casting (conversion)
sorting
Default memberwise assignment
recursive function
3. Words that are used for special purposes in a program
left
Counter-controlled or definite
opened
reserved words
4. Creates a copy of a string.
static
return
strcpy()
variable
5. You can reassign the operator features in C++ to do things other than what they would do naturally. This is called ____________
Closing brace
assignment statement
function overloading
operator overloading
6. A constant object must be __________; it cannot be modified after it is created.
like-type expression
const datatype identifier = value
/n
initialized
7. Variables declared in a block or in the parameter list of a function are assumed to be of storage class ________ unless specified otherwise.
auto
heap
return
address
8. Function ________ is used to produce random numbers.
type
Semicolon
allocating memory
rand
9. In inheritance the ____________ is the class that supplies the inherited members.
cin.get(ch)
base class
recursive
rand
10. You must have a ___________ for every variable you intend to use in a program
mixed expression
type
assignment
definition
11. An array that uses two subscripts is referred to as a(n) _________ array.
type coercion
endl (same as 'n')
two-dimensional
if...else
12. ________ is a graphical language that allows people who design software systems to use an industry-standard notation to represent them.
rand
private
comments
Unified Modeling Language(UML)
13. The process of analyzing and designing a system from an object-oriented point of view is called ________.
unary scope resolution operator (::)
escape sequences
object-oriented analysis and design (OOAD)
cout
14. Header file that contains commonly performed mathematical functions
preprocessor
identifiers
cmath
named constant
15. If a member initializer is not provided for a member object of a class the object's __________ is called.
default constructor
operand value
floating-point
const
16. 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.
assignment statement
virtual functions
recursive function
left
17. Member objects are constructed __________ their enclosing class object.
Stack overflow
before
strcpy()
data type
18. 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
19. Characters used to separate symbols or reserved words or identifiers and statements
whitespace
break
associations
stack
20. When the compiler sees this keyword the function call is replaced with a copy of the contents of the function itself.
inline functions
access specifier
continue
initialized
21. A sequence of operands and operators that describe a calculation to be performed
function parameters
token
arithmetic expression
type casting (conversion)
22. Executable version of program
return
if...else
object file
setw
23. 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.
global
showpoint
definition
void
24. The four areas that a program uses memory on are: the codes area - the _______ area - the stack and the heap.
Default memberwise assignment
rand
globals
global
25. Default name of executable file
base class
reserve words
a.out
void pointer
26. Most calculations are normally performed by ______ statements.
>>
reserved words
preprocessor
assignment
27. 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.
function overloading
inheritance
/n
<<
28. A function that can be used to read character data including whitespace
non-static
like-type expression
cin.get(ch)
return
29. The process of placing the elements of an array in order is called ________ the array.
base
preprocessor
operator overloading
sorting
30. In inheritance the ____________ is the class the receives the inherited members.
derived class
.cpp
if
fixed
31. Grammar rules of the language; compiler will try to identify and locate syntax errors
syntax
information hiding
function call
like-type expression
32. Message displayed to the screen asking user for input; generated with an output statement
prompt
cin
#include directive
static
33. The ________ enables access to a global variable with the same name as a variable in the current scope.
token
unary scope resolution operator (::)
showpoint
static
34. For every opening brace in a C++ program there must be a ______________.
case sensitive
arithmetic expression
Closing brace
subscript (or index)
35. Symbol that denotes an action to be performed
/n
operator
opened
operand value
36. Initializers __________ must be used to initialize constant members of a class.
&
definition
member
srand
37. Nonexecutable statements that are included in a program to provide information about what the program does etc.
type casting (conversion)
object-oriented analysis and design (OOAD)
comments
new line
38. The new operator dynamically allocates memory for an object of a specified type and returns a __________ to that type.
comments
&
non-static
pointer
39. A memory location with a name and data type and a value - its content (value) cannot be changed during program execution
named constant
?
definition
editor
40. The symbol for the binary scope resolution operator
::
#include directive
semantics
cmath
41. Repeating a set of instructions a specific number of times is called_________repetition.
new line
before
Counter-controlled or definite
reserve words
42. The ________ statement in a called function passes the value of an expression back to the calling function.
register
operator
return
subscript (or index)
43. A member function should be declared static if it does not access __________ class members.
variables
unary operator
non-static
attributes
44. C++ programs are normally typed into a computer using a(n) ________ program.
Unified Modeling Language(UML)
editor
void
token
45. The_________selection statement is used to execute one action when a condition is TRue or a different action when that condition is false.
identifiers
polymorphism
% modulus
if...else
46. The escape sequence n represents the _________ character which causes the cursor to position to the beginning of the next line on the screen.
before
token
new line
const
47. The sign you use for references
static
vectors
left
&
48. Names of things that are used in a program - can apply to variables & constants and functions
operator
dot (.)
identifiers
mixed expression
49. Type casting syntax
static_cast<char>(65)
?
function call
register
50. A file must be ________ before data can be written to or read from it.
member
opened
left
operator overloading