Next: Exercises
Up: A simple C++ program
Previous: Multiple Choice Questions
pi
as 3.1415927.i
and
j
and float variables x
and y
. Extend your
declaration statements so that i
and j
are both
initialised to 1 and y
is initialised to 10.0.first
, second
and
third
.x
in a
line as follows:
The value of x is ......
A circle of radius ..... has area ..... and circumference .....where the values of the radius, the area and the circumference are held in variables
rad
, area
, and circum
.include iostream.h Main(); { Float x,y,z; cout < "Enter two numbers "; cin >> a >> b cout << 'The numbers in reverse order are' << b,a; }
Download copy to try it.
total
has the value 352.74.cout << "The final total is: " << endl; cout << "$" << total << endl;
Next: Exercises
Up: A simple C++ program
Previous: Multiple Choice Questions