decimalPlaces

public static double decimalPlaces(double value, int places)

Rounds a number to a specified number of decimal places.

Return

The rounded number.

Parameters

value

The number to round.

places

The number of decimal places to round to.


public static float decimalPlaces(float value, int places)