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. In inheritance the ____________ is the class the receives the inherited members.
derived class
operator
#include
opened
2. In inheritance the ____________ is the class that supplies the inherited members.
opened
Literals
prompt
base class
3. You can reassign the operator features in C++ to do things other than what they would do naturally. This is called ____________
operator overloading
heap
non-static
derived class
4. Associate an identifier with a memory location
fstream
void
object-oriented analysis and design (OOAD)
allocating memory
5. The escape sequence n represents the _________ character which causes the cursor to position to the beginning of the next line on the screen.
new line
return
{ }
if
6. A __________ should be used to declare the size of an array because it makes the program more scalable.
cin >> variable
strcmp()
template
constant variable
7. The modulus operator (%) can be used only with __________.
integer operands
Sentinel
% modulus
void
8. A C++ statement that makes a decision is ______.
type
scope resolution operator
inheritance
if
9. A member function should be declared static if it does not access __________ class members.
comments
recursive function
non-static
&
10. Used for function calls and local variables
type coercion
return
classes
stack
11. ________ is a graphical language that allows people who design software systems to use an industry-standard notation to represent them.
cin.get(ch)
Unified Modeling Language(UML)
stack
two-dimensional
12. The _____ causes the contents of another file to be inserted into a program.
n
switch
binary operator
#include directive
13. Syntax for named constant declaration
base
const datatype identifier = value
inheritance
.cpp
14. The four areas that a program uses memory on are: the codes area - the _______ area - the stack and the heap.
named constant
semicolon
globals
polymorphism
15. Repeating a set of instructions a specific number of times is called_________repetition.
mixed expression
Counter-controlled or definite
friend
int values
16. A filestream variable that represents the default output device
object file
cout
register
left
17. Single letters or digits or special symbols; enclose value in single quotes ('a' '?' '8')
static
function scope
char
Unified Modeling Language(UML)
18. Default name of executable file
linker
named constant
a.out
base
19. 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
escape sequences
selection
#include directive
base
20. The process of placing the elements of an array in order is called ________ the array.
prompt
recursive
vectors
sorting
21. 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.
reserved words
local variable
static
Unified Modeling Language(UML)
22. Can be used as a compound "if" statement. it includes a number of different possibilities and directions rather than a single test.
switch
derived class
reserve words
non-static
23. int namespace include using return examples of ___________
char
reserve words
sorting
public
24. It is possible to have various functions with the same name that operate on different types or numbers of arguments. This is called function ________.
NULL
overloading
Arithmetic Operators
auto
25. An expression in which all operands have the same data type - result will have the same data type as operands
like-type expression
return
0
left
26. The only integer that can be assigned directly to a pointer is_____________.
0
binary operator
inheritance
private
27. Meaning of the instructions in the language; compiler cannot find these errors - often called logic errors
semantics
const
classes
private
28. Identifier or expression that is part of the calculation to be performed
operand value
token
#include
classes
29. The three values that can be used to initialize a pointer are 0 - __________ and an address.
#include
operator overloading
NULL
Unified Modeling Language(UML)
30. A function that calls itself either directly or indirectly - through another function) - is a ________ function.
::
address
recursive
static
31. Message displayed to the screen asking user for input; generated with an output statement
#include <headerfilename>
variable
heap
prompt
32. Preprocessor directive syntax
Literals
function scope
#include <headerfilename>
integer operands
33. The elements of an array are related by the fact that they have the same name and ___________.
type
operator
assignment statement
mixed expression
34. Class members specified as _________ are accessible anywhere an object of the class is in scope.
selection
strcmp()
public
void pointer
35. Keyword public is a(n) _________
Stack overflow
access specifier
if...else
rand
36. Class members specified as _________ are accessible only to member functions of the class and friends of the class.
polymorphism
private
if...else
stack
37. The ________ program combines the output of the compiler with various library functions to produce an executable image.
linker
static
semicolon
void pointer
38. Used for dynamically allocated variables
getline
break
delete
heap
39. All ______ must be declared before they are used.
return
integer operands
variables
type
40. Whole numbers - no decimals and no commas included
overloading
.cpp
comments
int values
41. An expression that has operands with different data types
auto
mixed expression
unary scope resolution operator (::)
globals
42. Header file that contains commonly performed mathematical functions
fixed
cmath
binary operator
default constructor
43. A nonmember function must be declared as a(n) __________ of a class to have access to that class's private data members.
n
friend
strcmp()
function prototype
44. This manipulator causes the field to be left-justified with padding spaces printed to the right.
Closing brace
cin >> variable
strlen()
left
45. C++ programs are normally typed into a computer using a(n) ________ program.
preprocessor
variable
editor
register
46. Characters used to separate symbols or reserved words or identifiers and statements
address
variable
whitespace
object-oriented analysis and design (OOAD)
47. Lists and tables of values can be stored in arrays or __________.
rand
vectors
a.out
definition
48. A variable declared outside any block or function is a ________ variable.
strcpy()
pointer
inline functions
global
49. Initializers __________ must be used to initialize constant members of a class.
member
endl (same as 'n')
left
t
50. A function is invoked with a ________.
static_cast<char>(65)
new line
function call
non-static
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