Country Language Codes : Country Codes « I18N « Java Tutorial






import java.util.Locale;

public class CountryLanguageCodes {

  public static void main(String [] argv) {

    String [] countries = Locale.getISOCountries();
    String [] languages = Locale.getISOLanguages();
    int i;

    System.out.println("\nCountries:\n");
    for (i = 0; i < countries.length; i++)
      System.out.println(countries[i]);
    System.out.println("\nLanguages:\n");
    for (i = 0; i < languages.length; i++)
      System.out.println(languages[i]);
  }
}








13.3.Country Codes
13.3.1.Examples of ISO 3166 Country Codes
13.3.2.Country Language Codes