16: Which of the following is true? a. Assigning a double value to an int does n
ID: 3887707 • Letter: 1
Question
16: Which of the following is true? a. Assigning a double value to an int does not lose any data b. For tal-type that could result in data loss c. For f could result in data loss. d. None of the above 17: Which of the a. C++ requires all variables to have a type. b. C++ c. ints may be 64 bits on some machines d. C+t programmers frequently have to write different versions of programs for different l types are portable. platforms 18: An example of a relational operator is: b. The a ass C.The % d. The ! to type will result in the loss of data 19: Converting from type a. bool, char c. int, char d. short, long 20: Recursion is to the base case as iteration is to what: a. The counter b. A repetition structure. c. Failure of the loop continuation test. by the following code (6 points) 21. Show the output produced endl cout ss (-7 3+6012 - 11) coutExplanation / Answer
16) b For fundamental-type conversion list initialisation prevents narrowing conversion that would result in data loss
17 d) C++ is cross-platform language.
18) a < is relational operator
19 converting from int to char will result in loss of data because int > char
20) Failure of loop continuation [Reason Recursion stops in base case so loop will stop if continuation test fails]
21) -21 + 30 +. 11 = 9 + 11 = 20
22) 3*2 +. 25/2 = 6 + 12 = 18
Thanks, let me know if there is any concern
Related Questions
Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.