BigDecimal: currency fractions
parent
eb1620c483
commit
b64682a003
|
@ -5,10 +5,15 @@ import java.util.Currency;
|
||||||
|
|
||||||
public class BigDecimalExample {
|
public class BigDecimalExample {
|
||||||
public static void main(String[] args) {
|
public static void main(String[] args) {
|
||||||
fromInteger();
|
// fromInteger();
|
||||||
fromFloat();
|
// fromFloat();
|
||||||
a();
|
// a();
|
||||||
b();
|
// b();
|
||||||
|
|
||||||
|
Currency eur = Currency.getInstance("EUR");
|
||||||
|
System.out.println("EUR: " + eur.getDefaultFractionDigits());
|
||||||
|
Currency tnd = Currency.getInstance("TND");
|
||||||
|
System.out.println("TND:" + tnd.getDefaultFractionDigits());
|
||||||
}
|
}
|
||||||
|
|
||||||
static void fromInteger() {
|
static void fromInteger() {
|
||||||
|
|
Loading…
Reference in New Issue