1:41 am - Wednesday February 22, 2017

Currency in java example program for getSymbol()

CANDID INDUSTRIAL TRAINING -- CHENNAI
Corporate Training for Experienced Candidate
Struts | Hibernate | Spring | Java / J2EE
SOAP | RestFull | Design Pattern | more...
Ph: +91 72000 69003
137b, 2nd st, shanthi nagar, Chrompet, Chennai -600044

/**
*@author: candidjava
*@description: Currency in JAVA example program for getSymbol()
**/
import java.util.Currency;

public class Getsymbol {
public static void main(String[] args) {
// create a currency for euro
Currency curr = Currency.getInstance("EUR");
// get and print the symbol of the currency
String symbol = curr.getSymbol();
System.out.println("Currency symbol is = " + symbol);
}
}

Output:

Currency symbol is = EUR

BACK

Filed in: Z-A All Java Codes

Comments are closed.