Question: Suppose x1 and x2 are two type double variables that you want to add as integers and assign to an integer variable. Construct a C++
Suppose x1 and x2 are two type double variables that you want to add as integers and assign to an integer variable. Construct a C++ statement for doing so. What if you want to add them as type double and then convert to int?
Step by Step Solution
3.38 Rating (148 Votes )
There are 3 Steps involved in it
Answer and Explanation int x1 2 int x2 3 int sum1 x1 x2 double sum2 staticcast x1 ... View full answer
Get step-by-step solutions from verified subject matter experts
