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 __________ operator reclaims memory previously allocated by new.
srand
delete
non-static
pointer
2. A filestream variable that represents the default output device
case sensitive
register
cin >> variable
cout
3. newline
if...else
*
cout
n
4. __________ can be used to assign an object of a class to another object of the same class.
Default memberwise assignment
setw
inheritance
&
5. Forces the computer to display decimal point and trailing zeroes
showpoint
cin >> variable
new line
global
6. A program that finds and attaches to your program the indicated libraries for compilation
operator overloading
.cpp
preprocessor
Stack overflow
7. Returns the length of a string excluding the null terminator.
member
private
data type
strlen()
8. A variable that is known only within the function in which it is defined is called a ________.
static
attributes
opened
local variable
9. Use 2 characters to represent one
operand value
.cpp
void
escape sequences
10. The storage-class specifiers are mutable - auto - ________ - extern and static.
//
new line
operator
register
11. An expression that has operands with different data types
associations
mixed expression
Default memberwise assignment
globals
12. The only integer that can be assigned directly to a pointer is_____________.
0
function overloading
case sensitive
semicolon
13. A set of values together with a set of operations
data type
function scope
static_cast<char>(65)
static
14. Naming convention for C++ programs
scope resolution operator
function call
.cpp
escape sequences
15. Smallest individual unit of a programming language - special symbols or word symbols or identifiers
getline
function prototype
recursive
token
16. The four areas that a program uses memory on are: the codes area - the _______ area - the stack and the heap.
const
endl (same as 'n')
globals
named constant
17. Can be used as a compound "if" statement. it includes a number of different possibilities and directions rather than a single test.
linker
semantics
mixed expression
switch
18. Syntax for named constant declaration
semantics
Stack overflow
const datatype identifier = value
new line
19. All programs can be written in terms of three types of control structures:Sequence - ________and Repetition.
selection
Semicolon
void
void
20. The ________ program transfers the executable image of a C++ program from disk to memory.
loader
ofstream
Counter-controlled or definite
void
21. 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.
Arithmetic Operators
?
/n
cin >> variable
22. Used for function calls and local variables
preprocessor
cout
recursive
stack
23. 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
fstream
Unified Modeling Language(UML)
static
24. An operator that can only be used with int values. result will always be an int.
unary scope resolution operator (::)
% modulus
local variable
default constructor
25. Keyword public is a(n) _________
assignment statement
operand value
access specifier
associations
26. A human readable file that contains C++ program
function scope
definition
source file
default constructor
27. It is possible to have various functions with the same name that operate on different types or numbers of arguments. This is called function ________.
inheritance
void pointer
overloading
opened
28. ________ is a graphical language that allows people who design software systems to use an industry-standard notation to represent them.
{ }
strlen()
inline functions
Unified Modeling Language(UML)
29. A member function should be declared static if it does not access __________ class members.
associations
non-static
operator overloading
vectors
30. The_________selection statement is used to execute one action when a condition is TRue or a different action when that condition is false.
const
//
if...else
{ }
31. Meaning of the instructions in the language; compiler cannot find these errors - often called logic errors
NULL
const
//
semantics
32. The stream extraction operator
>>
data type
this
variables
33. An expression in which all operands have the same data type - result will have the same data type as operands
new line
void
srand
like-type expression
34. The number used to refer to a particular element of an array is called its ________.
subscript (or index)
Preprocessor
const
vectors
35. Every C++ statement ends with a(n) _________.
semicolon
classes
derived class
base class
36. The elements of an array are related by the fact that they have the same name and ___________.
type
const
t
initialized
37. A C++ statement that makes a decision is ______.
if
int values
constant variable
preprocessor
38. 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.
void
operator overloading
virtual functions
object-oriented analysis and design (OOAD)
39. A variable declared outside any block or function is a ________ variable.
static
global
>>
member
40. A ________ program executes before the compiler's translation phase begins.
&
binary operator
preprocessor
editor
41. Words that are used for special purposes in a program
allocating memory
reserved words
strcpy()
token
42. 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
43. To allow file access in a program you must #include this header file.
fstream
definition
cout
recursive
44. These are data items whose values do not change while the program is running
function scope
Literals
cout
unary scope resolution operator (::)
45. Function ________ is used to set the random number seed to randomize a program.
virtual functions
/n
friend
srand
46. Comments do not cause the computer to print the text after the____ on the screen when the program is executed.
linker
//
Preprocessor
vectors
47. A function that can be used to read character data including whitespace
constant variable
two-dimensional
cin.get(ch)
named constant
48. * / % + -
non-static
escape sequences
Arithmetic Operators
type
49. Associate an identifier with a memory location
allocating memory
address
public
floating-point
50. Whole numbers - no decimals and no commas included
attributes
int values
selection
integer operands
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