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 three ways to return control from a called function to a caller are ________ - return expression and encounter.
recursive
inheritance
return
heap
2. Two slash marks ( // ) indicate __________ of a comment
#include <headerfilename>
fixed
Arithmetic Operators
beginning
3. A set of values together with a set of operations
mixed expression
base class
source file
data type
4. To explicitly indicate that a value is to be converted to another type
semantics
type casting (conversion)
escape sequences
selection
5. The _________ begins the body of every function and the _________ ends the body of every function.
void
{ }
return
operator
6. C++ programs are normally typed into a computer using a(n) ________ program.
type casting (conversion)
private
editor
scope
7. data types that refer to numbers with decimals
whitespace
floating-point
public
inheritance
8. You must have a ___________ for every variable you intend to use in a program
constant variable
searching
sorting
definition
9. The ________ enables access to a global variable with the same name as a variable in the current scope.
unary scope resolution operator (::)
*
fstream
dot (.)
10. A program that finds and attaches to your program the indicated libraries for compilation
constant variable
t
preprocessor
function prototype
11. Member objects are constructed __________ their enclosing class object.
assignment statement
loader
before
case sensitive
12. A variable that is known only within the function in which it is defined is called a ________.
&
unary scope resolution operator (::)
local variable
default constructor
13. A sequence of operands and operators that describe a calculation to be performed
type coercion
srand
arithmetic expression
main
14. Initializers __________ must be used to initialize constant members of a class.
inheritance
function call
allocating memory
member
15. Classes can have relationships with other classes. These relationships are called ________.
Semicolon
beginning
pointer
associations
16. The process of determining if an array contains a particular key value is called _________ the array.
source file
Sentinel
derived class
searching
17. These are data items whose values do not change while the program is running
register
Literals
operator
a.out
18. 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.
variables
definition
information hiding
static
19. 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
20. A __________ should be used to declare the size of an array because it makes the program more scalable.
inline functions
default constructor
continue
constant variable
21. Header file that contains commonly performed mathematical functions
cmath
function scope
information hiding
mixed expression
22. A human readable file that contains C++ program
operand value
srand
source file
preprocessor
23. ________ is a graphical language that allows people who design software systems to use an industry-standard notation to represent them.
inline functions
Unified Modeling Language(UML)
selection
main
24. Names of things that are used in a program - can apply to variables & constants and functions
% modulus
access specifier
linker
identifiers
25. Function ________ is used to produce random numbers.
rand
strcpy()
polymorphism
getline
26. Message displayed to the screen asking user for input; generated with an output statement
object-oriented analysis and design (OOAD)
endl (same as 'n')
local variable
prompt
27. 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
pointer
base
escape sequences
#include <headerfilename>
28. The three values that can be used to initialize a pointer are 0 - __________ and an address.
vectors
data type
NULL
cmath
29. An operator that can only be used with int values. result will always be an int.
classes
named constant
&
% modulus
30. * / % + -
Literals
Arithmetic Operators
Stack overflow
void pointer
31. You can reassign the operator features in C++ to do things other than what they would do naturally. This is called ____________
operator overloading
if...else
n
scope
32. When the compiler sees this keyword the function call is replaced with a copy of the contents of the function itself.
inline functions
::
fixed
0
33. 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.
virtual functions
Preprocessor
register
Closing brace
34. Smallest individual unit of a programming language - special symbols or word symbols or identifiers
special symbols
token
subscript (or index)
<<
35. Every C++ program begins execution at the function _________.
address
overloading
main
const
36. Every C++ statement ends with a(n) _________.
continue
0
semicolon
NULL
37. Sets floating-point values to a fixed decimal format
Stack overflow
fixed
preprocessor
const
38. This happens when too much memory is pushed onto the stack and overflows to other areas of memory.
Stack overflow
opened
strcpy()
two-dimensional
39. Most calculations are normally performed by ______ statements.
type
operator overloading
inline functions
assignment
40. An object's non-static member functions have access to a "self pointer" to the object called the __________ pointer.
local variable
prompt
this
operator overloading
41. The escape sequence n represents the _________ character which causes the cursor to position to the beginning of the next line on the screen.
srand
::
new line
void
42. The process of placing the elements of an array in order is called ________ the array.
Closing brace
sorting
Unified Modeling Language(UML)
recursive function
43. The only integer that can be assigned directly to a pointer is_____________.
assignment statement
subscript (or index)
const
0
44. The symbol for the binary scope resolution operator
scope resolution operator
::
special symbols
friend
45. Causes the program exits the loop - skipping over the rest of the commands and starts executing again with the next thing outside the loop.
Semicolon
cin.get(ch)
break
void pointer
46. Lists and tables of values can be stored in arrays or __________.
semantics
scope resolution operator
vectors
rand
47. A __________ data member represents class-wide information.
type casting (conversion)
template
static
function call
48. Return type _________ indicates that a function will perform a task but will not return any information when it completes its task.
void
default constructor
static_cast<char>(65)
function call
49. newline
n
delete
ofstream
private
50. A ________ program executes before the compiler's translation phase begins.
preprocessor
assignment statement
data type
//