Answers for "roundup to nearest whole number"

0

round to nearest step

function round(number, increment, offset) {
    return Math.ceil((number - offset) / increment ) * increment + offset;
}
round(51,  20, 10) // 70
round(70,  20, 10) // 70
round(99,  20, 10) // 110
round(100, 20, 10) // 110
Posted by: Guest on July-19-2021
-1

round off and round up

double roundOff = (double) Math.round(a * 100) / 100;
Posted by: Guest on October-15-2021

Code answers related to "roundup to nearest whole number"

Code answers related to "Java"

Java Answers by Framework

Browse Popular Code Answers by Language