When calculating a baseball players average, the average variable should be defi
ID: 3596588 • Letter: W
Question
When calculating a baseball players average, the average variable should be defined as a ____________.
float
int
string
char
Which of the following C++ statements correctly subtracts the number 40 from an int variable named hours, and stores the result in an int variabled named overTimeHours?
hours - 40 = overTimeHours;
overTimeHours = 40 - hours;
40 - hours = overTimeHours;
overTimeHours = hours - 40;
Which of the following input statements is correct?
cin >> total amount;
cin << total amount;
cin >> totalAmount;
cin << totalAmount;
Which of the following statements correctly reserves a named constant named CITY. Use the string literal constant "Dallas" to initialize the memory location.
const string CITY = "Dallas";
string CITY = "Dallas";
const String CITY = "Dallas";
const string CITY = Dallas;
Afloat
Bint
Cstring
Dchar
Explanation / Answer
When calculating a baseball players average, the average variable should be defined as a ____________.
float
int
string
char
Average should be a floating point number
Which of the following C++ statements correctly subtracts the number 40 from an int variable named hours, and stores the result in an int variabled named overTimeHours?
hours - 40 = overTimeHours;
overTimeHours = 40 - hours;
40 - hours = overTimeHours;
overTimeHours = hours - 40;
Which of the following input statements is correct?
cin >> total amount;
cin << total amount;
cin >> totalAmount;
cin << totalAmount;
There should not be any space and cin works with ">>"
Which of the following statements correctly reserves a named constant named CITY. Use the string literal constant "Dallas" to initialize the memory location.
const string CITY = "Dallas";
string CITY = "Dallas";
const String CITY = "Dallas";
const string CITY = Dallas;
Afloat
Bint
Cstring
Dchar
Average should be a floating point number
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.