Deck 2: Introduction to C Plus Plus

Full screen (f)
exit full mode
Question
The ________ is/are used to display information on the computer's screen.

A)Opening and closing braces
B)Opening and closing quotation marks
C)cout object
D)Backslash
E)None of the above
Use Space or
up arrow
down arrow
to flip the card.
Question
Which escape sequence causes the cursor to move to the beginning of the current line?

A)\n
B)\t
C)\a
D)\b
E)\r
Question
What is the modulus operator?

A)+
B)*
C)&
D)%
E) <strong>What is the modulus operator?</strong> A)+ B)* C)& D)% E)   <div style=padding-top: 35px>
Question
You must have a ________ for every variable you intend to use in a program.

A)purpose
B)definition
C)comment
D)constant
E)None of the above
Question
This is used to mark the end of a complete C++ programming statement.

A)Pound Sign
B)Semicolon
C)Data type
D)Void
E)None of the above
Question
Which data type typically requires only one byte of storage?

A)short
B)int
C)float
D)char
E)double
Question
These are data items whose values do not change while the program is running.

A)Literals
B)Variables
C)Comments
D)Integers
E)None of the above
Question
Which character signifies the beginning of an escape sequence?

A)//
B)/
C)\
D)#
E){
Question
________ represent storage locations in the computer's memory.

A)Literals
B)Variables
C)Comments
D)Integers
E)None of the above
Question
In a C++ program, two slash marks ( // )indicate:

A)The end of a statement
B)The beginning of a comment
C)The end of the program
D)The beginning of a block of code
E)None of the above
Question
In programming terms, a group of characters inside a set of quotation marks is called a(n):

A)String literal
B)Variable
C)Operation
D)Statement
E)None of the above
Question
Besides decimal, two other number systems you might encounter in C++ programs are:

A)Octal and Fractal
B)Hexadecimal and Octal
C)Unary and Quaternary
D)Base 7 and Base 9
E)None of the above
Question
In memory, C++ automatically places a ________ at the end of string literals.

A)Semicolon
B)Quotation marks
C)Null terminator
D)Newline escape sequence
E)None of the above
Question
A statement that starts with a # symbol is called a:

A)Comment
B)Function
C)Preprocessor directive
D)Key word
E)None of the above
Question
A character literal is enclosed in ________ quotation marks, whereas a string literal is enclosed in ________ quotation marks.

A)double, single
B)triple, double
C)open, closed
D)single, double
E)None of the above
Question
The ________ causes the contents of another file to be inserted into a program.

A)Backslash
B)Pound sign
C)Semicolon
D)#include directive
E)None of the above
Question
For every opening brace in a C++ program, there must be a:

A)String literal
B)Function
C)Variable
D)Closing brace
E)None of the above
Question
Of the following, which is a valid C++ identifier?

A)June1997
B)_employee_number
C)___department
D)myExtraLongVariableName
E)All of the above are valid identifiers.
Question
The numeric data types in C++ can be broken into two general categories:

A)numbers and characters
B)singles and doubles
C)integer and floating point
D)real and unreal
E)None of the above
Question
What is the output of the following statement?
Cout << 4 * (15 / (1 + 3))<< endl;

A)15
B)12
C)63
D)72
E)None of these
Question
Which one of the following would be an illegal variable name?

A)dayOfWeek
B)3dGraph
C)_employee_num
D)June1997
E)itemsorderedforthemonth
Question
Every complete C++ program must have a ________.

A)comment
B)function named main
C)preprocessor directive
D)symbolic constant
E)cout statement
Question
What will the following code display?
<strong>What will the following code display?  </strong> A)  B)  C)  D)  <div style=padding-top: 35px>

A)<strong>What will the following code display?  </strong> A)  B)  C)  D)  <div style=padding-top: 35px>
B)<strong>What will the following code display?  </strong> A)  B)  C)  D)  <div style=padding-top: 35px>
C)<strong>What will the following code display?  </strong> A)  B)  C)  D)  <div style=padding-top: 35px>
D)<strong>What will the following code display?  </strong> A)  B)  C)  D)  <div style=padding-top: 35px>
Question
This control sequence is used to skip over to the next horizontal tab stop.

A)\n
B)\h
C)\t
D)\a
E)\'
Question
This function in C++ allows you to identify how many bytes of storage on your computer system an integer data value requires.

A)len
B)bytes
C)f(x)
D)int
E)sizeof
Question
Character constants in C++ are always enclosed in ________.

A)[brackets]
B)"double quotation marks"
C)'single quotation marks'
D){braces}
E)(parentheses)
Question
What is the value of cookies after the execution of the following statements?
Int number = 38, children = 4, cookies;
Cookies = number % children;

A)2
B)0
C)9
D).5
E)None of these
Question
If you use a C++ key word as an identifier, your program will:

A)Execute with unpredictable results
B)not compile
C)understand the difference and run without problems
D)Compile, link, but not execute
E)None of the above
Question
What will the following code display?
<strong>What will the following code display?  </strong> A)  B)  C)  D)  <div style=padding-top: 35px>

A)<strong>What will the following code display?  </strong> A)  B)  C)  D)  <div style=padding-top: 35px>
B)<strong>What will the following code display?  </strong> A)  B)  C)  D)  <div style=padding-top: 35px>
C)<strong>What will the following code display?  </strong> A)  B)  C)  D)  <div style=padding-top: 35px>
D)<strong>What will the following code display?  </strong> A)  B)  C)  D)  <div style=padding-top: 35px>
Question
What will the following code display?
<strong>What will the following code display?  </strong> A)   B)   C)   D)   <div style=padding-top: 35px>

A) <strong>What will the following code display?  </strong> A)   B)   C)   D)   <div style=padding-top: 35px>
B) <strong>What will the following code display?  </strong> A)   B)   C)   D)   <div style=padding-top: 35px>
C) <strong>What will the following code display?  </strong> A)   B)   C)   D)   <div style=padding-top: 35px>
D) <strong>What will the following code display?  </strong> A)   B)   C)   D)   <div style=padding-top: 35px>
Question
________ must be included in any program that uses the cout object.

A)Opening and closing braces
B)The header file iostream
C)Comments
D)Escape sequences
E)None of the above
Question
Look at the following program and answer the question that follows it. <strong>Look at the following program and answer the question that follows it.   Which line(s) in this program cause output to be displayed on the screen?</strong> A)13 and 14 B)8 and 9 C)14 D)13 E)15 <div style=padding-top: 35px>
Which line(s) in this program cause output to be displayed on the screen?

A)13 and 14
B)8 and 9
C)14
D)13
E)15
Question
These are used to declare variables that can hold real numbers.

A)Integer data types
B)Real data types
C)Floating point data types
D)Long data types
E)None of the above
Question
What will the following code display?
<strong>What will the following code display?   </strong> A)  B)  C)  D)  <div style=padding-top: 35px>

A)<strong>What will the following code display?   </strong> A)  B)  C)  D)  <div style=padding-top: 35px>
B)<strong>What will the following code display?   </strong> A)  B)  C)  D)  <div style=padding-top: 35px>
C)<strong>What will the following code display?   </strong> A)  B)  C)  D)  <div style=padding-top: 35px>
D)<strong>What will the following code display?   </strong> A)  B)  C)  D)  <div style=padding-top: 35px>
Question
What will the following code display?
<strong>What will the following code display?  </strong> A)The number is 7 B)The number is number C)The number is7 D)The number is 0 <div style=padding-top: 35px>

A)The number is 7
B)The number is number
C)The number is7
D)The number is 0
Question
The float data type is considered ________ precision, and the double data type is considered ________ precision.

A)single, double
B)float, double
C)integer, double
D)short, long
E)None of the above
Question
A variable whose value can be either true or false is of this data type.

A)binary
B)bool
C)T/F
D)float
E)None of the above
Question
A variable's ________ is the part of the program that has access to the variable.

A)data type
B)value
C)scope
D)reach
E)None of the above
Question
Which of the following correctly consolidates the following declaration statements into one statement?
Int x = 7;
Int y = 16;
Int z = 28;

A)int x = 7; y = 16; z = 28;
B)int x = 7   y = 16   z = 28;
C)int x, y, z = 7, 16, 28
D)int x = 7, y = 16, z = 28;
E)None of these will work.
Question
Which of the following defines a double-precision floating point variable named payCheck?

A)float payCheck;
B)double payCheck;
C)payCheck double;
D)Double payCheck;
Question
What will the following code display?
<strong>What will the following code display?  </strong> A)   B)   C)   D)   <div style=padding-top: 35px>

A) <strong>What will the following code display?  </strong> A)   B)   C)   D)   <div style=padding-top: 35px>
B) <strong>What will the following code display?  </strong> A)   B)   C)   D)   <div style=padding-top: 35px>
C) <strong>What will the following code display?  </strong> A)   B)   C)   D)   <div style=padding-top: 35px>
D) <strong>What will the following code display?  </strong> A)   B)   C)   D)   <div style=padding-top: 35px>
Question
If you do not follow a consistent programming style, your programs will generate compiler errors.
Question
Assuming you are using a system with 1-byte characters, how many bytes of memory will the following string literal occupy?
"William"

A)7
B)14
C)8
D)1
Question
The first step in using the string class is to #include the ________ header file.

A)iostream
B)cctype
C)cmath
D)string
E)None of the above
Question
C++ does not have a built in data type for storing strings of characters.
Question
When typing in your source code into the computer, you must be very careful since most of your C++ instructions, header files, and variable names are case sensitive.
Question
A variable called "average" should be declared as an integer data type because it will probably hold data that contains decimal places.
Question
What will the value of x be after the following statements execute?
Int x;
X = 18 / 4;

A)4.5
B)4
C)0
D)unknown
Question
Floating point constants are normally stored in memory as doubles.
Question
The C++ language requires that you give variables names that indicate what the variables are used for.
Question
Assume that a program has the following string object definition: string name;
Which of the following statements correctly assigns a string literal to the string object?

A)name = Jane;
B)name = "Jane";
C)name = 'Jane';
D)name = (Jane);
Question
When writing long integer literals or long long integer literals in C++ 11, you can use either an uppercase or lowercase L.
Question
Escape sequences are always stored internally as a single character.
Question
In C++ 11, if you want an integer literal to be treated as a long long int, you can append ________ at the end of the number.

A)L
B)
C)I
D)LL
E)None of the above
Question
What will the value of x be after the following statements execute?
Int x;
X = 18 % 4;

A)0.45
B)4
C)2
D)unknown
Question
Assume that a program has the following variable definition: char letter;
Which of the following statements correctly assigns the character Z to the variable?

A)letter = Z;
B)letter = "Z";
C)letter = 'Z';
D)letter = (Z);
Question
In C++ 11, the ________ tells the compiler to determine the variable's data type from the initialization value.

A)auto key word
B)#include preprocessor directive
C)variable's name
D)dynamic_cast key word
E)None of the above
Question
C++ 11 introduces an alternative way to define variables, using the template key word and an initialization value.
Question
What will the value of x be after the following statements execute?
Int x;
X = 18.0 / 4;

A)4.5
B)4
C)0
D)unknown
Question
A preprocessor directive does not require a semicolon at the end.
Unlock Deck
Sign up to unlock the cards in this deck!
Unlock Deck
Unlock Deck
1/60
auto play flashcards
Play
simple tutorial
Full screen (f)
exit full mode
Deck 2: Introduction to C Plus Plus
1
The ________ is/are used to display information on the computer's screen.

A)Opening and closing braces
B)Opening and closing quotation marks
C)cout object
D)Backslash
E)None of the above
cout object
2
Which escape sequence causes the cursor to move to the beginning of the current line?

A)\n
B)\t
C)\a
D)\b
E)\r
\r
3
What is the modulus operator?

A)+
B)*
C)&
D)%
E) <strong>What is the modulus operator?</strong> A)+ B)* C)& D)% E)
%
4
You must have a ________ for every variable you intend to use in a program.

A)purpose
B)definition
C)comment
D)constant
E)None of the above
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
5
This is used to mark the end of a complete C++ programming statement.

A)Pound Sign
B)Semicolon
C)Data type
D)Void
E)None of the above
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
6
Which data type typically requires only one byte of storage?

A)short
B)int
C)float
D)char
E)double
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
7
These are data items whose values do not change while the program is running.

A)Literals
B)Variables
C)Comments
D)Integers
E)None of the above
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
8
Which character signifies the beginning of an escape sequence?

A)//
B)/
C)\
D)#
E){
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
9
________ represent storage locations in the computer's memory.

A)Literals
B)Variables
C)Comments
D)Integers
E)None of the above
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
10
In a C++ program, two slash marks ( // )indicate:

A)The end of a statement
B)The beginning of a comment
C)The end of the program
D)The beginning of a block of code
E)None of the above
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
11
In programming terms, a group of characters inside a set of quotation marks is called a(n):

A)String literal
B)Variable
C)Operation
D)Statement
E)None of the above
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
12
Besides decimal, two other number systems you might encounter in C++ programs are:

A)Octal and Fractal
B)Hexadecimal and Octal
C)Unary and Quaternary
D)Base 7 and Base 9
E)None of the above
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
13
In memory, C++ automatically places a ________ at the end of string literals.

A)Semicolon
B)Quotation marks
C)Null terminator
D)Newline escape sequence
E)None of the above
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
14
A statement that starts with a # symbol is called a:

A)Comment
B)Function
C)Preprocessor directive
D)Key word
E)None of the above
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
15
A character literal is enclosed in ________ quotation marks, whereas a string literal is enclosed in ________ quotation marks.

A)double, single
B)triple, double
C)open, closed
D)single, double
E)None of the above
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
16
The ________ causes the contents of another file to be inserted into a program.

A)Backslash
B)Pound sign
C)Semicolon
D)#include directive
E)None of the above
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
17
For every opening brace in a C++ program, there must be a:

A)String literal
B)Function
C)Variable
D)Closing brace
E)None of the above
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
18
Of the following, which is a valid C++ identifier?

A)June1997
B)_employee_number
C)___department
D)myExtraLongVariableName
E)All of the above are valid identifiers.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
19
The numeric data types in C++ can be broken into two general categories:

A)numbers and characters
B)singles and doubles
C)integer and floating point
D)real and unreal
E)None of the above
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
20
What is the output of the following statement?
Cout << 4 * (15 / (1 + 3))<< endl;

A)15
B)12
C)63
D)72
E)None of these
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
21
Which one of the following would be an illegal variable name?

A)dayOfWeek
B)3dGraph
C)_employee_num
D)June1997
E)itemsorderedforthemonth
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
22
Every complete C++ program must have a ________.

A)comment
B)function named main
C)preprocessor directive
D)symbolic constant
E)cout statement
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
23
What will the following code display?
<strong>What will the following code display?  </strong> A)  B)  C)  D)

A)<strong>What will the following code display?  </strong> A)  B)  C)  D)
B)<strong>What will the following code display?  </strong> A)  B)  C)  D)
C)<strong>What will the following code display?  </strong> A)  B)  C)  D)
D)<strong>What will the following code display?  </strong> A)  B)  C)  D)
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
24
This control sequence is used to skip over to the next horizontal tab stop.

A)\n
B)\h
C)\t
D)\a
E)\'
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
25
This function in C++ allows you to identify how many bytes of storage on your computer system an integer data value requires.

A)len
B)bytes
C)f(x)
D)int
E)sizeof
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
26
Character constants in C++ are always enclosed in ________.

A)[brackets]
B)"double quotation marks"
C)'single quotation marks'
D){braces}
E)(parentheses)
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
27
What is the value of cookies after the execution of the following statements?
Int number = 38, children = 4, cookies;
Cookies = number % children;

A)2
B)0
C)9
D).5
E)None of these
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
28
If you use a C++ key word as an identifier, your program will:

A)Execute with unpredictable results
B)not compile
C)understand the difference and run without problems
D)Compile, link, but not execute
E)None of the above
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
29
What will the following code display?
<strong>What will the following code display?  </strong> A)  B)  C)  D)

A)<strong>What will the following code display?  </strong> A)  B)  C)  D)
B)<strong>What will the following code display?  </strong> A)  B)  C)  D)
C)<strong>What will the following code display?  </strong> A)  B)  C)  D)
D)<strong>What will the following code display?  </strong> A)  B)  C)  D)
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
30
What will the following code display?
<strong>What will the following code display?  </strong> A)   B)   C)   D)

A) <strong>What will the following code display?  </strong> A)   B)   C)   D)
B) <strong>What will the following code display?  </strong> A)   B)   C)   D)
C) <strong>What will the following code display?  </strong> A)   B)   C)   D)
D) <strong>What will the following code display?  </strong> A)   B)   C)   D)
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
31
________ must be included in any program that uses the cout object.

A)Opening and closing braces
B)The header file iostream
C)Comments
D)Escape sequences
E)None of the above
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
32
Look at the following program and answer the question that follows it. <strong>Look at the following program and answer the question that follows it.   Which line(s) in this program cause output to be displayed on the screen?</strong> A)13 and 14 B)8 and 9 C)14 D)13 E)15
Which line(s) in this program cause output to be displayed on the screen?

A)13 and 14
B)8 and 9
C)14
D)13
E)15
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
33
These are used to declare variables that can hold real numbers.

A)Integer data types
B)Real data types
C)Floating point data types
D)Long data types
E)None of the above
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
34
What will the following code display?
<strong>What will the following code display?   </strong> A)  B)  C)  D)

A)<strong>What will the following code display?   </strong> A)  B)  C)  D)
B)<strong>What will the following code display?   </strong> A)  B)  C)  D)
C)<strong>What will the following code display?   </strong> A)  B)  C)  D)
D)<strong>What will the following code display?   </strong> A)  B)  C)  D)
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
35
What will the following code display?
<strong>What will the following code display?  </strong> A)The number is 7 B)The number is number C)The number is7 D)The number is 0

A)The number is 7
B)The number is number
C)The number is7
D)The number is 0
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
36
The float data type is considered ________ precision, and the double data type is considered ________ precision.

A)single, double
B)float, double
C)integer, double
D)short, long
E)None of the above
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
37
A variable whose value can be either true or false is of this data type.

A)binary
B)bool
C)T/F
D)float
E)None of the above
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
38
A variable's ________ is the part of the program that has access to the variable.

A)data type
B)value
C)scope
D)reach
E)None of the above
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
39
Which of the following correctly consolidates the following declaration statements into one statement?
Int x = 7;
Int y = 16;
Int z = 28;

A)int x = 7; y = 16; z = 28;
B)int x = 7   y = 16   z = 28;
C)int x, y, z = 7, 16, 28
D)int x = 7, y = 16, z = 28;
E)None of these will work.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
40
Which of the following defines a double-precision floating point variable named payCheck?

A)float payCheck;
B)double payCheck;
C)payCheck double;
D)Double payCheck;
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
41
What will the following code display?
<strong>What will the following code display?  </strong> A)   B)   C)   D)

A) <strong>What will the following code display?  </strong> A)   B)   C)   D)
B) <strong>What will the following code display?  </strong> A)   B)   C)   D)
C) <strong>What will the following code display?  </strong> A)   B)   C)   D)
D) <strong>What will the following code display?  </strong> A)   B)   C)   D)
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
42
If you do not follow a consistent programming style, your programs will generate compiler errors.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
43
Assuming you are using a system with 1-byte characters, how many bytes of memory will the following string literal occupy?
"William"

A)7
B)14
C)8
D)1
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
44
The first step in using the string class is to #include the ________ header file.

A)iostream
B)cctype
C)cmath
D)string
E)None of the above
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
45
C++ does not have a built in data type for storing strings of characters.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
46
When typing in your source code into the computer, you must be very careful since most of your C++ instructions, header files, and variable names are case sensitive.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
47
A variable called "average" should be declared as an integer data type because it will probably hold data that contains decimal places.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
48
What will the value of x be after the following statements execute?
Int x;
X = 18 / 4;

A)4.5
B)4
C)0
D)unknown
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
49
Floating point constants are normally stored in memory as doubles.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
50
The C++ language requires that you give variables names that indicate what the variables are used for.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
51
Assume that a program has the following string object definition: string name;
Which of the following statements correctly assigns a string literal to the string object?

A)name = Jane;
B)name = "Jane";
C)name = 'Jane';
D)name = (Jane);
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
52
When writing long integer literals or long long integer literals in C++ 11, you can use either an uppercase or lowercase L.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
53
Escape sequences are always stored internally as a single character.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
54
In C++ 11, if you want an integer literal to be treated as a long long int, you can append ________ at the end of the number.

A)L
B)
C)I
D)LL
E)None of the above
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
55
What will the value of x be after the following statements execute?
Int x;
X = 18 % 4;

A)0.45
B)4
C)2
D)unknown
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
56
Assume that a program has the following variable definition: char letter;
Which of the following statements correctly assigns the character Z to the variable?

A)letter = Z;
B)letter = "Z";
C)letter = 'Z';
D)letter = (Z);
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
57
In C++ 11, the ________ tells the compiler to determine the variable's data type from the initialization value.

A)auto key word
B)#include preprocessor directive
C)variable's name
D)dynamic_cast key word
E)None of the above
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
58
C++ 11 introduces an alternative way to define variables, using the template key word and an initialization value.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
59
What will the value of x be after the following statements execute?
Int x;
X = 18.0 / 4;

A)4.5
B)4
C)0
D)unknown
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
60
A preprocessor directive does not require a semicolon at the end.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
locked card icon
Unlock Deck
Unlock for access to all 60 flashcards in this deck.