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. 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.
delete
template
assignment
static
2. Nonexecutable statements that are included in a program to provide information about what the program does etc.
comments
.cpp
dot (.)
named constant
3. Smallest individual unit of a programming language - special symbols or word symbols or identifiers
.cpp
token
const
stack
4. A variable that holds the address of another variable.
cout
/n
register
pointer
5. The three values that can be used to initialize a pointer are 0 - __________ and an address.
NULL
this
whitespace
::
6. The stream insertion operator
this
default constructor
semantics
<<
7. 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.
inheritance
arithmetic expression
selection
unary scope resolution operator (::)
8. Allows the programmer to store a value in a variable
assignment statement
attributes
friend
strcpy()
9. The_________selection statement is used to execute one action when a condition is TRue or a different action when that condition is false.
if...else
derived class
operator overloading
escape sequences
10. Characters used to separate symbols or reserved words or identifiers and statements
srand
whitespace
base class
vectors
11. A function is invoked with a ________.
preprocessor
function call
unary operator
% modulus
12. Used for dynamically allocated variables
recursive function
Closing brace
heap
virtual functions
13. Used for function calls and local variables
stack
function scope
two-dimensional
cin >> variable
14. Use 2 characters to represent one
assignment
address
void pointer
escape sequences
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.
function scope
continue
strcpy()
?
16. * / % + -
Closing brace
void pointer
Arithmetic Operators
two-dimensional
17. The size & shape & color and weight of an object are considered
attributes
classes
const
% modulus
18. Class members are accessed via the ________ operator in conjunction with the name of an object (or reference to an object) of the class or via the arrow (->) operator in conjunction with a pointer to an object of the class.
identifiers
dot (.)
% modulus
char
19. The new operator dynamically allocates memory for an object of a specified type and returns a __________ to that type.
&
?
pointer
Closing brace
20. 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
base
special symbols
% modulus
prompt
21. The number used to refer to a particular element of an array is called its ________.
subscript (or index)
friend
const
#include directive
22. When a value of one data type is implicitly (automatically) changed to another data type
two-dimensional
a.out
type coercion
private
23. The process of analyzing and designing a system from an object-oriented point of view is called ________.
private
global
object-oriented analysis and design (OOAD)
assignment statement
24. An operator that can only be used with int values. result will always be an int.
overloading
definition
two-dimensional
% modulus
25. __________ can be used to assign an object of a class to another object of the same class.
void
named constant
Default memberwise assignment
access specifier
26. When the compiler sees this keyword the function call is replaced with a copy of the contents of the function itself.
assignment
inline functions
inheritance
special symbols
27. A human readable file that contains C++ program
strcpy()
source file
globals
type casting (conversion)
28. A memory location with a name and data type and a value - its content (value) cannot be changed during program execution
inheritance
non-static
template
named constant
29. 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.
template
switch
const
continue
30. Operator with only one operand
unary operator
source file
{ }
globals
31. The process of placing the elements of an array in order is called ________ the array.
sorting
main
unary scope resolution operator (::)
classes
32. A________ allows the compiler to check the number & types and order of the arguments passed to a function.
% modulus
function prototype
cin >> variable
/n
33. A set of values together with a set of operations
setw
base
data type
function parameters
34. A __________ data member represents class-wide information.
semantics
fstream
static
scope resolution operator
35. This manipulator is used to establish a field width for the value immediately following it.
strcpy()
setw
if...else
named constant
36. The ________ statement in a called function passes the value of an expression back to the calling function.
base class
global
return
virtual functions
37. Initializers __________ must be used to initialize constant members of a class.
variables
>>
member
heap
38. Words that are used for special purposes in a program
reserved words
assignment statement
pointer
Literals
39. The only integer that can be assigned directly to a pointer is_____________.
auto
a.out
0
Stack overflow
40. You can declare default values for a function in the ____________________.
binary operator
function scope
function parameters
like-type expression
41. For every opening brace in a C++ program there must be a ______________.
object-oriented analysis and design (OOAD)
Closing brace
assignment
const
42. Single letters or digits or special symbols; enclose value in single quotes ('a' '?' '8')
/n
char
scope
static
43. The ________ qualifier is used to declare read-only variables.
n
searching
attributes
const
44. These are data items whose values do not change while the program is running
cmath
Literals
friend
strcmp()
45. Identifier or expression that is part of the calculation to be performed
type
fixed
continue
operand value
46. Repeating a set of instructions a specific number of times is called_________repetition.
Counter-controlled or definite
object file
semicolon
virtual functions
47. Syntax for named constant declaration
variables
#include directive
token
const datatype identifier = value
48. A function ________ enables a single function to be defined to perform a task on many different data types.
member
template
special symbols
loader
49. This manipulator causes the field to be left-justified with padding spaces printed to the right.
allocating memory
Unified Modeling Language(UML)
semicolon
left
50. An expression that has operands with different data types
unary scope resolution operator (::)
mixed expression
Literals
friend
Sorry!:) No result found.
Can you answer 50 questions in 15 minutes?
Let me suggest you:
Browse all subjects
Browse all tests
Most popular tests
Major Subjects
Tests & Exams
AP
CLEP
DSST
GRE
SAT
GMAT
Certifications
CISSP go to https://www.isc2.org/
PMP
ITIL
RHCE
MCTS
More...
IT Skills
Android Programming
Data Modeling
Objective C Programming
Basic Python Programming
Adobe Illustrator
More...
Business Skills
Advertising Techniques
Business Accounting Basics
Business Strategy
Human Resource Management
Marketing Basics
More...
Soft Skills
Body Language
People Skills
Public Speaking
Persuasion
Job Hunting And Resumes
More...
Vocabulary
GRE Vocab
SAT Vocab
TOEFL Essential Vocab
Basic English Words For All
Global Words You Should Know
Business English
More...
Languages
AP German Vocab
AP Latin Vocab
SAT Subject Test: French
Italian Survival
Norwegian Survival
More...
Engineering
Audio Engineering
Computer Science Engineering
Aerospace Engineering
Chemical Engineering
Structural Engineering
More...
Health Sciences
Basic Nursing Skills
Health Science Language Fundamentals
Veterinary Technology Medical Language
Cardiology
Clinical Surgery
More...
English
Grammar Fundamentals
Literary And Rhetorical Vocab
Elements Of Style Vocab
Introduction To English Major
Complete Advanced Sentences
Literature
Homonyms
More...
Math
Algebra Formulas
Basic Arithmetic: Measurements
Metric Conversions
Geometric Properties
Important Math Facts
Number Sense Vocab
Business Math
More...
Other Major Subjects
Science
Economics
History
Law
Performing-arts
Cooking
Logic & Reasoning
Trivia
Browse all subjects
Browse all tests
Most popular tests