Hi,
i'm still not clear about how to round a decimal number.....can anyone give me some specific example?
I'm told that, to round a decimal number, i have to first multiply the decimal number(double) with 100, then only i 'assign' it to an integer...but how do i do that? Any one tried this way before?
Lets say i have a code:
double total=0;
double sum;
.......................
total = total + sum;
After that i need to round the total (dollars) to nearest 5 cents. How to do that?