I am working on a project for class. I need to round a large number ex.((pi to 10 power)or(93650.237398) to the nearest hundred (93700). We need to use one of the cmath library functions to do this. I can not figure out which one to use. Can someone point me in the right direction
This should do it.
Basically, it removes the two last digits before it rounds, which makes it equivalent to rounding to the nearest 100. Then it multiplies by 100 to add the 00's back in.
Uncomment the other numbers to see if their results are to your liking.