Answers for "Round to Nearest 1000"

0

Round to Nearest 1000

Decimal d = 1234.56;
system.debug(d.setScale(-3)); // 1000
system.debug(d.setScale(-3, RoundingMode.CEILING)); // 2000
Posted by: Guest on March-31-2022

Browse Popular Code Answers by Language