Java Data Type Tutorial - Java BigDecimal ONE








Syntax

BigDecimal.ONE has the following syntax.

public static final BigDecimal ONE

Example

In the following code shows how to use BigDecimal.ONE field.

import java.math.BigDecimal;

public class Main {

  public static void main(String[] args) {

    System.out.println(BigDecimal.ONE);
  }
}

The code above generates the following result.