How to write any decimal number and round it up to closest decimal .

  • Thread starter Thread starter Pofche
  • Start date Start date
P

Pofche

Guest
Hi

I want the program to round up to closest decimal. Like if I ask the user to write a decimal number.

And then ask him how many decimals he wants. So if he writes the number 1,3457322 and writes that he want 5 decimals. Then the program shall write back 1,34573 and also 3 decimals back 1,346. I know its about float but i cant find the round up sign.

Continue reading...
 
Back
Top