Question: Double userInput is read from input. Write a while loop that iterates while userInput is greater than 1 . 0 . In each iteration: Update

Double userInput is read from input. Write a while loop that iterates while userInput is greater than 1.0. In each iteration:
Update userInput with the quotient of userInput and 6.0.
Output the updated userInput, followed by a newline.
Ex: If the input is -12.4-26.0-13.3-9.2-12.8-13.5, then the output is:
-12.4 is kept -26 is filtered off
Note: -15.0 and 25.0 are not in the given range.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!