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. The storage-class specifiers are mutable - auto - ________ - extern and static.
left
register
char
pointer
2. The sign you use for pointers
globals
&
*
const
3. ________ is a graphical language that allows people who design software systems to use an industry-standard notation to represent them.
virtual functions
function parameters
pointer
Unified Modeling Language(UML)
4. The ________ program combines the output of the compiler with various library functions to produce an executable image.
token
pointer
linker
associations
5. A variable that is known only within the function in which it is defined is called a ________.
function call
const
local variable
overloading
6. A type of pointer that can point at objects of any data type.
inline functions
void pointer
Semicolon
classes
7. A filestream variable that represents the default output device
new line
Preprocessor
void
cout
8. The escape sequence n represents the _________ character which causes the cursor to position to the beginning of the next line on the screen.
Preprocessor
new line
endl (same as 'n')
syntax
9. The ________ of an identifier is the portion of the program in which the identifier can be used.
NULL
#include directive
scope
derived class
10. A function ________ enables a single function to be defined to perform a task on many different data types.
template
left
int values
constant variable
11. The three values that can be used to initialize a pointer are 0 - __________ and an address.
definition
integer operands
continue
NULL
12. Naming convention for C++ programs
a.out
template
cmath
.cpp
13. A memory location with a name and data type and a value - its content (value) cannot be changed during program execution
named constant
const
break
scope resolution operator
14. The process of determining if an array contains a particular key value is called _________ the array.
searching
inline functions
.cpp
left
15. 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.
NULL
inheritance
opened
void
16. Symbol that denotes an action to be performed
classes
type casting (conversion)
#include directive
operator
17. A recursive function typically has two components: One that provides a means for the recursion to terminate by testing for a(n) ________ case and one that expresses the problem as a recursive call for a slightly simpler problem than the original call
const datatype identifier = value
base
named constant
0
18. The _________ begins the body of every function and the _________ ends the body of every function.
auto
polymorphism
Closing brace
{ }
19. Characters used to separate symbols or reserved words or identifiers and statements
whitespace
n
Preprocessor
like-type expression
20. The symbol for the binary scope resolution operator
function call
getline
::
.cpp
21. A C++ statement that makes a decision is ______.
escape sequences
variable
if
allocating memory
22. Function ________ is used to produce random numbers.
before
rand
special symbols
vectors
23. The ________ qualifier is used to declare read-only variables.
loader
function scope
const
associations
24. Compares two strings and returns 0 if they are equal.
assignment
srand
strlen()
strcmp()
25. 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.
continue
function overloading
like-type expression
reserved words
26. 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.
static
% modulus
inline functions
&
27. Used to qualify hidden names so that they can be used.
inheritance
type coercion
identifiers
scope resolution operator
28. The process of placing the elements of an array in order is called ________ the array.
dot (.)
object-oriented analysis and design (OOAD)
sorting
switch
29. Variables declared in a block or in the parameter list of a function are assumed to be of storage class ________ unless specified otherwise.
preprocessor
auto
return
assignment
30. 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
31. Type casting syntax
arithmetic expression
static_cast<char>(65)
cin.get(ch)
static
32. The_________selection statement is used to execute one action when a condition is TRue or a different action when that condition is false.
Literals
if...else
//
const datatype identifier = value
33. A nonmember function must be declared as a(n) __________ of a class to have access to that class's private data members.
Arithmetic Operators
friend
sorting
fixed
34. Allows the programmer to store a value in a variable
integer operands
assignment statement
const
ofstream
35. C++ programs are normally typed into a computer using a(n) ________ program.
non-static
mixed expression
fixed
editor
36. Use 2 characters to represent one
t
type casting (conversion)
globals
escape sequences
37. A __________ data member represents class-wide information.
Sentinel
cmath
static
switch
38. A variable that holds the address of another variable.
NULL
stack
pointer
initialized
39. Executable version of program
escape sequences
object file
subscript (or index)
virtual functions
40. A function that calls itself
&
fixed
recursive function
token
41. A function that can be used to read character data including whitespace
&
pointer
cin.get(ch)
arithmetic expression
42. In inheritance the ____________ is the class that supplies the inherited members.
char
Counter-controlled or definite
initialized
base class
43. Creates a copy of a string.
.cpp
prompt
associations
strcpy()
44. Function ________ is used to set the random number seed to randomize a program.
srand
break
function parameters
operator overloading
45. A file must be ________ before data can be written to or read from it.
mixed expression
operator overloading
opened
like-type expression
46. Return type _________ indicates that a function will perform a task but will not return any information when it completes its task.
void
>>
classes
Default memberwise assignment
47. Two slash marks ( // ) indicate __________ of a comment
access specifier
Semicolon
friend
beginning
48. All programs can be written in terms of three types of control structures:Sequence - ________and Repetition.
.cpp
selection
non-static
classes
49. Used for dynamically allocated variables
heap
0
prompt
auto
50. The __________ operator reclaims memory previously allocated by new.
delete
object-oriented analysis and design (OOAD)
token
n