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. Objects have the property of ________although objects may know how to communicate with one another across well-defined interfaces - they normally are not allowed to know how other objects are implemented.
semicolon
information hiding
strcpy()
int values
2. If a member initializer is not provided for a member object of a class the object's __________ is called.
default constructor
void pointer
switch
cmath
3. Smallest individual unit of a programming language - special symbols or word symbols or identifiers
token
searching
named constant
new line
4. The three ways to return control from a called function to a caller are ________ - return expression and encounter.
#include <headerfilename>
.cpp
strcmp()
return
5. The storage-class specifiers are mutable - auto - ________ - extern and static.
::
register
information hiding
fstream
6. The symbol for the binary scope resolution operator
special symbols
public
::
{ }
7. __________ can be used to assign an object of a class to another object of the same class.
Default memberwise assignment
//
NULL
token
8. A file must be ________ before data can be written to or read from it.
opened
% modulus
token
void
9. data types that refer to numbers with decimals
heap
void pointer
object file
floating-point
10. The stream insertion operator
//
<<
non-static
two-dimensional
11. 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.
% modulus
continue
allocating memory
//
12. Initializers __________ must be used to initialize constant members of a class.
Counter-controlled or definite
strlen()
default constructor
member
13. A __________ data member represents class-wide information.
before
address
function scope
static
14. Compares two strings and returns 0 if they are equal.
selection
strcmp()
fixed
sorting
15. This manipulator is used to establish a field width for the value immediately following it.
static
case sensitive
setw
static_cast<char>(65)
16. Function ________ is used to set the random number seed to randomize a program.
srand
main
<<
pointer
17. The _________ begins the body of every function and the _________ ends the body of every function.
{ }
void pointer
comments
setw
18. A function that can be used to read character data including whitespace
function prototype
cin.get(ch)
*
static_cast<char>(65)
19. ________ is a graphical language that allows people who design software systems to use an industry-standard notation to represent them.
Unified Modeling Language(UML)
assignment
beginning
Default memberwise assignment
20. A variable that holds the address of another variable.
inheritance
t
information hiding
pointer
21. A function is invoked with a ________.
if...else
function call
#include
.cpp
22. Two slash marks ( // ) indicate __________ of a comment
default constructor
beginning
type
//
23. A filestream variable that represents the default output device
#include directive
variable
cout
::
24. Member objects are constructed __________ their enclosing class object.
this
access specifier
before
>>
25. Identifier or expression that is part of the calculation to be performed
return
break
operand value
arithmetic expression
26. 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.
?
Sentinel
>>
virtual functions
27. An object's non-static member functions have access to a "self pointer" to the object called the __________ pointer.
classes
operand value
recursive
this
28. Preprocessor directive syntax
cin
*
Closing brace
#include <headerfilename>
29. All ______ must be declared before they are used.
vectors
definition
recursive function
variables
30. Most calculations are normally performed by ______ statements.
fixed
assignment
associations
int values
31. Grammar rules of the language; compiler will try to identify and locate syntax errors
object file
#include <headerfilename>
before
syntax
32. This happens when too much memory is pushed onto the stack and overflows to other areas of memory.
Stack overflow
this
>>
<<
33. The address-of operator. it is used to assign pointers and to print the address of variables.
&
strcmp()
non-static
#include directive
34. C++ programs are normally typed into a computer using a(n) ________ program.
register
editor
int values
static_cast<char>(65)
35. This manipulator causes the field to be left-justified with padding spaces printed to the right.
linker
syntax
0
left
36. This allows the writer to create functions of the same name as long as they have different parameters or different quantities of parameters.
function overloading
operand value
getline
auto
37. These are data items whose values do not change while the program is running
escape sequences
like-type expression
main
Literals
38. A filestream variable that represents the default input source
searching
static_cast<char>(65)
vectors
cin
39. The source-code file and any other files that use a class can include the class's header file via an _________ preprocessor directive.
break
ofstream
int values
#include
40. Keyword public is a(n) _________
data type
binary operator
access specifier
operand value
41. Type casting syntax
inheritance
static_cast<char>(65)
integer operands
data type
42. Class members specified as _________ are accessible only to member functions of the class and friends of the class.
private
function prototype
named constant
mixed expression
43. 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.
fstream
like-type expression
variable
dot (.)
44. The process of determining if an array contains a particular key value is called _________ the array.
0
base
token
searching
45. Creates a copy of a string.
token
cout
syntax
strcpy()
46. A program that finds and attaches to your program the indicated libraries for compilation
floating-point
preprocessor
return
classes
47. Operator with two operands
cin.get(ch)
binary operator
Counter-controlled or definite
//
48. Used for dynamically allocated variables
heap
const
a.out
return
49. Used to qualify hidden names so that they can be used.
named constant
scope resolution operator
pointer
*
50. A memory location with a name and data type and a value - its content (value) cannot be changed during program execution
named constant
&
cout
strcpy()
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