186k views
0 votes
Given a floating-point variable fraction, write a statement that writes the value of fraction to standard output. Do not write anything else to standard output -- just the value of fraction.

User Topo
by
5.2k points

1 Answer

2 votes

Answer:

The statement to this question is "cout << fraction;".

Step-by-step explanation:

In the given question it is declared, that a floating-point variable "fraction" is defined, which holds some value. To print this variable value in C++ program we use the print function, which is "cout". This function also used to print messages and values, in this question the print function uses the float variable "fraction", which prints variable value.

User Pierre Mardon
by
4.6k points