Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Countries HashMap with numeric code key.
countries = {
"004" => { "alpha-3-code" => "AFG", "alpha-2-code" => "AF", "name" => "Afghanistan" },
"248" => { "alpha-3-code" => "ALA", "alpha-2-code" => "AX", "name" => "Åland Islands" },
"008" => { "alpha-3-code" => "ALB", "alpha-2-code" => "AL", "name" => "Albania" },
"012" => { "alpha-3-code" => "DZA", "alpha-2-code" => "DZ", "name" => "Algeria" },
"016" => { "alpha-3-code" => "ASM", "alpha-2-code" => "AS", "name" => "American Samoa" },
"020" => { "alpha-3-code" => "AND", "alpha-2-code" => "AD", "name" => "Andorra" },
"024" => { "alpha-3-code" => "AGO", "alpha-2-code" => "AO", "name" => "Angola" },
"660" => { "alpha-3-code" => "AIA", "alpha-2-code" => "AI", "name" => "Anguilla" },
"010" => { "alpha-3-code" => "ATA", "alpha-2-code" => "AQ", "name" => "Antarctica" },
"028" => { "alpha-3-code" => "ATG", "alpha-2-code" => "AG", "name" => "Antigua and Barbuda" },
"032" => { "alpha-3-code" => "ARG", "alpha-2-code" => "AR", "name" => "Argentina" },
"051" => { "alpha-3-code" => "ARM", "alpha-2-code" => "AM", "name" => "Armenia" },
"533" => { "alpha-3-code" => "ABW", "alpha-2-code" => "AW", "name" => "Aruba" },
"036" => { "alpha-3-code" => "AUS", "alpha-2-code" => "AU", "name" => "Australia" },
"040" => { "alpha-3-code" => "AUT", "alpha-2-code" => "AT", "name" => "Austria" },
"031" => { "alpha-3-code" => "AZE", "alpha-2-code" => "AZ", "name" => "Azerbaijan" },
"044" => { "alpha-3-code" => "BHS", "alpha-2-code" => "BS", "name" => "Bahamas" },
"048" => { "alpha-3-code" => "BHR", "alpha-2-code" => "BH", "name" => "Bahrain" },
"050" => { "alpha-3-code" => "BGD", "alpha-2-code" => "BD", "name" => "Bangladesh" },
"052" => { "alpha-3-code" => "BRB", "alpha-2-code" => "BB", "name" => "Barbados" },
"112" => { "alpha-3-code" => "BLR", "alpha-2-code" => "BY", "name" => "Belarus" },
"056" => { "alpha-3-code" => "BEL", "alpha-2-code" => "BE", "name" => "Belgium" },
"084" => { "alpha-3-code" => "BLZ", "alpha-2-code" => "BZ", "name" => "Belize" },
"204" => { "alpha-3-code" => "BEN", "alpha-2-code" => "BJ", "name" => "Benin" },
"060" => { "alpha-3-code" => "BMU", "alpha-2-code" => "BM", "name" => "Bermuda" },
"064" => { "alpha-3-code" => "BTN", "alpha-2-code" => "BT", "name" => "Bhutan" },
"068" => { "alpha-3-code" => "BOL", "alpha-2-code" => "BO", "name" => "Bolivia, Plurinational State of" },
"535" => { "alpha-3-code" => "BES", "alpha-2-code" => "BQ", "name" => "Bonaire, Sint Eustatius and Saba" },
"070" => { "alpha-3-code" => "BIH", "alpha-2-code" => "BA", "name" => "Bosnia and Herzegovina" },
"072" => { "alpha-3-code" => "BWA", "alpha-2-code" => "BW", "name" => "Botswana" },
"074" => { "alpha-3-code" => "BVT", "alpha-2-code" => "BV", "name" => "Bouvet Island" },
"076" => { "alpha-3-code" => "BRA", "alpha-2-code" => "BR", "name" => "Brazil" },
"086" => { "alpha-3-code" => "IOT", "alpha-2-code" => "IO", "name" => "British Indian Ocean Territory" },
"096" => { "alpha-3-code" => "BRN", "alpha-2-code" => "BN", "name" => "Brunei Darussalam" },
"100" => { "alpha-3-code" => "BGR", "alpha-2-code" => "BG", "name" => "Bulgaria" },
"854" => { "alpha-3-code" => "BFA", "alpha-2-code" => "BF", "name" => "Burkina Faso" },
"108" => { "alpha-3-code" => "BDI", "alpha-2-code" => "BI", "name" => "Burundi" },
"116" => { "alpha-3-code" => "KHM", "alpha-2-code" => "KH", "name" => "Cambodia" },
"120" => { "alpha-3-code" => "CMR", "alpha-2-code" => "CM", "name" => "Cameroon" },
"124" => { "alpha-3-code" => "CAN", "alpha-2-code" => "CA", "name" => "Canada" },
"132" => { "alpha-3-code" => "CPV", "alpha-2-code" => "CV", "name" => "Cabo Verde" },
"136" => { "alpha-3-code" => "CYM", "alpha-2-code" => "KY", "name" => "Cayman Islands" },
"140" => { "alpha-3-code" => "CAF", "alpha-2-code" => "CF", "name" => "Central African Republic" },
"148" => { "alpha-3-code" => "TCD", "alpha-2-code" => "TD", "name" => "Chad" },
"152" => { "alpha-3-code" => "CHL", "alpha-2-code" => "CL", "name" => "Chile" },
"156" => { "alpha-3-code" => "CHN", "alpha-2-code" => "CN", "name" => "China" },
"162" => { "alpha-3-code" => "CXR", "alpha-2-code" => "CX", "name" => "Christmas Island" },
"166" => { "alpha-3-code" => "CCK", "alpha-2-code" => "CC", "name" => "Cocos (Keeling) Islands" },
"170" => { "alpha-3-code" => "COL", "alpha-2-code" => "CO", "name" => "Colombia" },
"174" => { "alpha-3-code" => "COM", "alpha-2-code" => "KM", "name" => "Comoros" },
"178" => { "alpha-3-code" => "COG", "alpha-2-code" => "CG", "name" => "Congo" },
"180" => { "alpha-3-code" => "COD", "alpha-2-code" => "CD", "name" => "Congo, the Democratic Republic of the" },
"184" => { "alpha-3-code" => "COK", "alpha-2-code" => "CK", "name" => "Cook Islands" },
"188" => { "alpha-3-code" => "CRI", "alpha-2-code" => "CR", "name" => "Costa Rica" },
"384" => { "alpha-3-code" => "CIV", "alpha-2-code" => "CI", "name" => "Côte d'Ivoire" },
"191" => { "alpha-3-code" => "HRV", "alpha-2-code" => "HR", "name" => "Croatia" },
"192" => { "alpha-3-code" => "CUB", "alpha-2-code" => "CU", "name" => "Cuba" },
"531" => { "alpha-3-code" => "CUW", "alpha-2-code" => "CW", "name" => "Curaçao" },
"196" => { "alpha-3-code" => "CYP", "alpha-2-code" => "CY", "name" => "Cyprus" },
"203" => { "alpha-3-code" => "CZE", "alpha-2-code" => "CZ", "name" => "Czech Republic" },
"208" => { "alpha-3-code" => "DNK", "alpha-2-code" => "DK", "name" => "Denmark" },
"262" => { "alpha-3-code" => "DJI", "alpha-2-code" => "DJ", "name" => "Djibouti" },
"212" => { "alpha-3-code" => "DMA", "alpha-2-code" => "DM", "name" => "Dominica" },
"214" => { "alpha-3-code" => "DOM", "alpha-2-code" => "DO", "name" => "Dominican Republic" },
"218" => { "alpha-3-code" => "ECU", "alpha-2-code" => "EC", "name" => "Ecuador" },
"818" => { "alpha-3-code" => "EGY", "alpha-2-code" => "EG", "name" => "Egypt" },
"222" => { "alpha-3-code" => "SLV", "alpha-2-code" => "SV", "name" => "El Salvador" },
"226" => { "alpha-3-code" => "GNQ", "alpha-2-code" => "GQ", "name" => "Equatorial Guinea" },
"232" => { "alpha-3-code" => "ERI", "alpha-2-code" => "ER", "name" => "Eritrea" },
"233" => { "alpha-3-code" => "EST", "alpha-2-code" => "EE", "name" => "Estonia" },
"231" => { "alpha-3-code" => "ETH", "alpha-2-code" => "ET", "name" => "Ethiopia" },
"238" => { "alpha-3-code" => "FLK", "alpha-2-code" => "FK", "name" => "Falkland Islands (Malvinas)" },
"234" => { "alpha-3-code" => "FRO", "alpha-2-code" => "FO", "name" => "Faroe Islands" },
"242" => { "alpha-3-code" => "FJI", "alpha-2-code" => "FJ", "name" => "Fiji" },
"246" => { "alpha-3-code" => "FIN", "alpha-2-code" => "FI", "name" => "Finland" },
"250" => { "alpha-3-code" => "FRA", "alpha-2-code" => "FR", "name" => "France" },
"254" => { "alpha-3-code" => "GUF", "alpha-2-code" => "GF", "name" => "French Guiana" },
"258" => { "alpha-3-code" => "PYF", "alpha-2-code" => "PF", "name" => "French Polynesia" },
"260" => { "alpha-3-code" => "ATF", "alpha-2-code" => "TF", "name" => "French Southern Territories" },
"266" => { "alpha-3-code" => "GAB", "alpha-2-code" => "GA", "name" => "Gabon" },
"270" => { "alpha-3-code" => "GMB", "alpha-2-code" => "GM", "name" => "Gambia" },
"268" => { "alpha-3-code" => "GEO", "alpha-2-code" => "GE", "name" => "Georgia" },
"276" => { "alpha-3-code" => "DEU", "alpha-2-code" => "DE", "name" => "Germany" },
"288" => { "alpha-3-code" => "GHA", "alpha-2-code" => "GH", "name" => "Ghana" },
"292" => { "alpha-3-code" => "GIB", "alpha-2-code" => "GI", "name" => "Gibraltar" },
"300" => { "alpha-3-code" => "GRC", "alpha-2-code" => "GR", "name" => "Greece" },
"304" => { "alpha-3-code" => "GRL", "alpha-2-code" => "GL", "name" => "Greenland" },
"308" => { "alpha-3-code" => "GRD", "alpha-2-code" => "GD", "name" => "Grenada" },
"312" => { "alpha-3-code" => "GLP", "alpha-2-code" => "GP", "name" => "Guadeloupe" },
"316" => { "alpha-3-code" => "GUM", "alpha-2-code" => "GU", "name" => "Guam" },
"320" => { "alpha-3-code" => "GTM", "alpha-2-code" => "GT", "name" => "Guatemala" },
"831" => { "alpha-3-code" => "GGY", "alpha-2-code" => "GG", "name" => "Guernsey" },
"324" => { "alpha-3-code" => "GIN", "alpha-2-code" => "GN", "name" => "Guinea" },
"624" => { "alpha-3-code" => "GNB", "alpha-2-code" => "GW", "name" => "Guinea-Bissau" },
"328" => { "alpha-3-code" => "GUY", "alpha-2-code" => "GY", "name" => "Guyana" },
"332" => { "alpha-3-code" => "HTI", "alpha-2-code" => "HT", "name" => "Haiti" },
"334" => { "alpha-3-code" => "HMD", "alpha-2-code" => "HM", "name" => "Heard Island and McDonald Islands" },
"336" => { "alpha-3-code" => "VAT", "alpha-2-code" => "VA", "name" => "Holy See (Vatican City State)" },
"340" => { "alpha-3-code" => "HND", "alpha-2-code" => "HN", "name" => "Honduras" },
"344" => { "alpha-3-code" => "HKG", "alpha-2-code" => "HK", "name" => "Hong Kong" },
"348" => { "alpha-3-code" => "HUN", "alpha-2-code" => "HU", "name" => "Hungary" },
"352" => { "alpha-3-code" => "ISL", "alpha-2-code" => "IS", "name" => "Iceland" },
"356" => { "alpha-3-code" => "IND", "alpha-2-code" => "IN", "name" => "India" },
"360" => { "alpha-3-code" => "IDN", "alpha-2-code" => "ID", "name" => "Indonesia" },
"364" => { "alpha-3-code" => "IRN", "alpha-2-code" => "IR", "name" => "Iran, Islamic Republic of" },
"368" => { "alpha-3-code" => "IRQ", "alpha-2-code" => "IQ", "name" => "Iraq" },
"372" => { "alpha-3-code" => "IRL", "alpha-2-code" => "IE", "name" => "Ireland" },
"833" => { "alpha-3-code" => "IMN", "alpha-2-code" => "IM", "name" => "Isle of Man" },
"376" => { "alpha-3-code" => "ISR", "alpha-2-code" => "IL", "name" => "Israel" },
"380" => { "alpha-3-code" => "ITA", "alpha-2-code" => "IT", "name" => "Italy" },
"388" => { "alpha-3-code" => "JAM", "alpha-2-code" => "JM", "name" => "Jamaica" },
"392" => { "alpha-3-code" => "JPN", "alpha-2-code" => "JP", "name" => "Japan" },
"832" => { "alpha-3-code" => "JEY", "alpha-2-code" => "JE", "name" => "Jersey" },
"400" => { "alpha-3-code" => "JOR", "alpha-2-code" => "JO", "name" => "Jordan" },
"398" => { "alpha-3-code" => "KAZ", "alpha-2-code" => "KZ", "name" => "Kazakhstan" },
"404" => { "alpha-3-code" => "KEN", "alpha-2-code" => "KE", "name" => "Kenya" },
"296" => { "alpha-3-code" => "KIR", "alpha-2-code" => "KI", "name" => "Kiribati" },
"408" => { "alpha-3-code" => "PRK", "alpha-2-code" => "KP", "name" => "Korea, Democratic People's Republic of" },
"410" => { "alpha-3-code" => "KOR", "alpha-2-code" => "KR", "name" => "Korea, Republic of" },
"414" => { "alpha-3-code" => "KWT", "alpha-2-code" => "KW", "name" => "Kuwait" },
"417" => { "alpha-3-code" => "KGZ", "alpha-2-code" => "KG", "name" => "Kyrgyzstan" },
"418" => { "alpha-3-code" => "LAO", "alpha-2-code" => "LA", "name" => "Lao People's Democratic Republic" },
"428" => { "alpha-3-code" => "LVA", "alpha-2-code" => "LV", "name" => "Latvia" },
"422" => { "alpha-3-code" => "LBN", "alpha-2-code" => "LB", "name" => "Lebanon" },
"426" => { "alpha-3-code" => "LSO", "alpha-2-code" => "LS", "name" => "Lesotho" },
"430" => { "alpha-3-code" => "LBR", "alpha-2-code" => "LR", "name" => "Liberia" },
"434" => { "alpha-3-code" => "LBY", "alpha-2-code" => "LY", "name" => "Libya" },
"438" => { "alpha-3-code" => "LIE", "alpha-2-code" => "LI", "name" => "Liechtenstein" },
"440" => { "alpha-3-code" => "LTU", "alpha-2-code" => "LT", "name" => "Lithuania" },
"442" => { "alpha-3-code" => "LUX", "alpha-2-code" => "LU", "name" => "Luxembourg" },
"446" => { "alpha-3-code" => "MAC", "alpha-2-code" => "MO", "name" => "Macao" },
"807" => { "alpha-3-code" => "MKD", "alpha-2-code" => "MK", "name" => "Macedonia, the former Yugoslav Republic of" },
"450" => { "alpha-3-code" => "MDG", "alpha-2-code" => "MG", "name" => "Madagascar" },
"454" => { "alpha-3-code" => "MWI", "alpha-2-code" => "MW", "name" => "Malawi" },
"458" => { "alpha-3-code" => "MYS", "alpha-2-code" => "MY", "name" => "Malaysia" },
"462" => { "alpha-3-code" => "MDV", "alpha-2-code" => "MV", "name" => "Maldives" },
"466" => { "alpha-3-code" => "MLI", "alpha-2-code" => "ML", "name" => "Mali" },
"470" => { "alpha-3-code" => "MLT", "alpha-2-code" => "MT", "name" => "Malta" },
"584" => { "alpha-3-code" => "MHL", "alpha-2-code" => "MH", "name" => "Marshall Islands" },
"474" => { "alpha-3-code" => "MTQ", "alpha-2-code" => "MQ", "name" => "Martinique" },
"478" => { "alpha-3-code" => "MRT", "alpha-2-code" => "MR", "name" => "Mauritania" },
"480" => { "alpha-3-code" => "MUS", "alpha-2-code" => "MU", "name" => "Mauritius" },
"175" => { "alpha-3-code" => "MYT", "alpha-2-code" => "YT", "name" => "Mayotte" },
"484" => { "alpha-3-code" => "MEX", "alpha-2-code" => "MX", "name" => "Mexico" },
"583" => { "alpha-3-code" => "FSM", "alpha-2-code" => "FM", "name" => "Micronesia, Federated States of" },
"498" => { "alpha-3-code" => "MDA", "alpha-2-code" => "MD", "name" => "Moldova, Republic of" },
"492" => { "alpha-3-code" => "MCO", "alpha-2-code" => "MC", "name" => "Monaco" },
"496" => { "alpha-3-code" => "MNG", "alpha-2-code" => "MN", "name" => "Mongolia" },
"499" => { "alpha-3-code" => "MNE", "alpha-2-code" => "ME", "name" => "Montenegro" },
"500" => { "alpha-3-code" => "MSR", "alpha-2-code" => "MS", "name" => "Montserrat" },
"504" => { "alpha-3-code" => "MAR", "alpha-2-code" => "MA", "name" => "Morocco" },
"508" => { "alpha-3-code" => "MOZ", "alpha-2-code" => "MZ", "name" => "Mozambique" },
"104" => { "alpha-3-code" => "MMR", "alpha-2-code" => "MM", "name" => "Myanmar" },
"516" => { "alpha-3-code" => "NAM", "alpha-2-code" => "NA", "name" => "Namibia" },
"520" => { "alpha-3-code" => "NRU", "alpha-2-code" => "NR", "name" => "Nauru" },
"524" => { "alpha-3-code" => "NPL", "alpha-2-code" => "NP", "name" => "Nepal" },
"528" => { "alpha-3-code" => "NLD", "alpha-2-code" => "NL", "name" => "Netherlands" },
"540" => { "alpha-3-code" => "NCL", "alpha-2-code" => "NC", "name" => "New Caledonia" },
"554" => { "alpha-3-code" => "NZL", "alpha-2-code" => "NZ", "name" => "New Zealand" },
"558" => { "alpha-3-code" => "NIC", "alpha-2-code" => "NI", "name" => "Nicaragua" },
"562" => { "alpha-3-code" => "NER", "alpha-2-code" => "NE", "name" => "Niger" },
"566" => { "alpha-3-code" => "NGA", "alpha-2-code" => "NG", "name" => "Nigeria" },
"570" => { "alpha-3-code" => "NIU", "alpha-2-code" => "NU", "name" => "Niue" },
"574" => { "alpha-3-code" => "NFK", "alpha-2-code" => "NF", "name" => "Norfolk Island" },
"580" => { "alpha-3-code" => "MNP", "alpha-2-code" => "MP", "name" => "Northern Mariana Islands" },
"578" => { "alpha-3-code" => "NOR", "alpha-2-code" => "NO", "name" => "Norway" },
"512" => { "alpha-3-code" => "OMN", "alpha-2-code" => "OM", "name" => "Oman" },
"586" => { "alpha-3-code" => "PAK", "alpha-2-code" => "PK", "name" => "Pakistan" },
"585" => { "alpha-3-code" => "PLW", "alpha-2-code" => "PW", "name" => "Palau" },
"275" => { "alpha-3-code" => "PSE", "alpha-2-code" => "PS", "name" => "Palestine, State of" },
"591" => { "alpha-3-code" => "PAN", "alpha-2-code" => "PA", "name" => "Panama" },
"598" => { "alpha-3-code" => "PNG", "alpha-2-code" => "PG", "name" => "Papua New Guinea" },
"600" => { "alpha-3-code" => "PRY", "alpha-2-code" => "PY", "name" => "Paraguay" },
"604" => { "alpha-3-code" => "PER", "alpha-2-code" => "PE", "name" => "Peru" },
"608" => { "alpha-3-code" => "PHL", "alpha-2-code" => "PH", "name" => "Philippines" },
"612" => { "alpha-3-code" => "PCN", "alpha-2-code" => "PN", "name" => "Pitcairn" },
"616" => { "alpha-3-code" => "POL", "alpha-2-code" => "PL", "name" => "Poland" },
"620" => { "alpha-3-code" => "PRT", "alpha-2-code" => "PT", "name" => "Portugal" },
"630" => { "alpha-3-code" => "PRI", "alpha-2-code" => "PR", "name" => "Puerto Rico" },
"634" => { "alpha-3-code" => "QAT", "alpha-2-code" => "QA", "name" => "Qatar" },
"638" => { "alpha-3-code" => "REU", "alpha-2-code" => "RE", "name" => "Réunion" },
"642" => { "alpha-3-code" => "ROU", "alpha-2-code" => "RO", "name" => "Romania" },
"643" => { "alpha-3-code" => "RUS", "alpha-2-code" => "RU", "name" => "Russian Federation" },
"646" => { "alpha-3-code" => "RWA", "alpha-2-code" => "RW", "name" => "Rwanda" },
"652" => { "alpha-3-code" => "BLM", "alpha-2-code" => "BL", "name" => "Saint Barthélemy" },
"654" => { "alpha-3-code" => "SHN", "alpha-2-code" => "SH", "name" => "Saint Helena, Ascension and Tristan da Cunha" },
"659" => { "alpha-3-code" => "KNA", "alpha-2-code" => "KN", "name" => "Saint Kitts and Nevis" },
"662" => { "alpha-3-code" => "LCA", "alpha-2-code" => "LC", "name" => "Saint Lucia" },
"663" => { "alpha-3-code" => "MAF", "alpha-2-code" => "MF", "name" => "Saint Martin (French part)" },
"666" => { "alpha-3-code" => "SPM", "alpha-2-code" => "PM", "name" => "Saint Pierre and Miquelon" },
"670" => { "alpha-3-code" => "VCT", "alpha-2-code" => "VC", "name" => "Saint Vincent and the Grenadines" },
"882" => { "alpha-3-code" => "WSM", "alpha-2-code" => "WS", "name" => "Samoa" },
"674" => { "alpha-3-code" => "SMR", "alpha-2-code" => "SM", "name" => "San Marino" },
"678" => { "alpha-3-code" => "STP", "alpha-2-code" => "ST", "name" => "Sao Tome and Principe" },
"682" => { "alpha-3-code" => "SAU", "alpha-2-code" => "SA", "name" => "Saudi Arabia" },
"686" => { "alpha-3-code" => "SEN", "alpha-2-code" => "SN", "name" => "Senegal" },
"688" => { "alpha-3-code" => "SRB", "alpha-2-code" => "RS", "name" => "Serbia" },
"690" => { "alpha-3-code" => "SYC", "alpha-2-code" => "SC", "name" => "Seychelles" },
"694" => { "alpha-3-code" => "SLE", "alpha-2-code" => "SL", "name" => "Sierra Leone" },
"702" => { "alpha-3-code" => "SGP", "alpha-2-code" => "SG", "name" => "Singapore" },
"534" => { "alpha-3-code" => "SXM", "alpha-2-code" => "SX", "name" => "Sint Maarten (Dutch part)" },
"703" => { "alpha-3-code" => "SVK", "alpha-2-code" => "SK", "name" => "Slovakia" },
"705" => { "alpha-3-code" => "SVN", "alpha-2-code" => "SI", "name" => "Slovenia" },
"090" => { "alpha-3-code" => "SLB", "alpha-2-code" => "SB", "name" => "Solomon Islands" },
"706" => { "alpha-3-code" => "SOM", "alpha-2-code" => "SO", "name" => "Somalia" },
"710" => { "alpha-3-code" => "ZAF", "alpha-2-code" => "ZA", "name" => "South Africa" },
"239" => { "alpha-3-code" => "SGS", "alpha-2-code" => "GS", "name" => "South Georgia and the South Sandwich Islands" },
"728" => { "alpha-3-code" => "SSD", "alpha-2-code" => "SS", "name" => "South Sudan" },
"724" => { "alpha-3-code" => "ESP", "alpha-2-code" => "ES", "name" => "Spain" },
"144" => { "alpha-3-code" => "LKA", "alpha-2-code" => "LK", "name" => "Sri Lanka" },
"729" => { "alpha-3-code" => "SDN", "alpha-2-code" => "SD", "name" => "Sudan" },
"740" => { "alpha-3-code" => "SUR", "alpha-2-code" => "SR", "name" => "Suriname" },
"744" => { "alpha-3-code" => "SJM", "alpha-2-code" => "SJ", "name" => "Svalbard and Jan Mayen" },
"748" => { "alpha-3-code" => "SWZ", "alpha-2-code" => "SZ", "name" => "Swaziland" },
"752" => { "alpha-3-code" => "SWE", "alpha-2-code" => "SE", "name" => "Sweden" },
"756" => { "alpha-3-code" => "CHE", "alpha-2-code" => "CH", "name" => "Switzerland" },
"760" => { "alpha-3-code" => "SYR", "alpha-2-code" => "SY", "name" => "Syrian Arab Republic" },
"158" => { "alpha-3-code" => "TWN", "alpha-2-code" => "TW", "name" => "Taiwan, Province of China" },
"762" => { "alpha-3-code" => "TJK", "alpha-2-code" => "TJ", "name" => "Tajikistan" },
"834" => { "alpha-3-code" => "TZA", "alpha-2-code" => "TZ", "name" => "Tanzania, United Republic of" },
"764" => { "alpha-3-code" => "THA", "alpha-2-code" => "TH", "name" => "Thailand" },
"626" => { "alpha-3-code" => "TLS", "alpha-2-code" => "TL", "name" => "Timor-Leste" },
"768" => { "alpha-3-code" => "TGO", "alpha-2-code" => "TG", "name" => "Togo" },
"772" => { "alpha-3-code" => "TKL", "alpha-2-code" => "TK", "name" => "Tokelau" },
"776" => { "alpha-3-code" => "TON", "alpha-2-code" => "TO", "name" => "Tonga" },
"780" => { "alpha-3-code" => "TTO", "alpha-2-code" => "TT", "name" => "Trinidad and Tobago" },
"788" => { "alpha-3-code" => "TUN", "alpha-2-code" => "TN", "name" => "Tunisia" },
"792" => { "alpha-3-code" => "TUR", "alpha-2-code" => "TR", "name" => "Turkey" },
"795" => { "alpha-3-code" => "TKM", "alpha-2-code" => "TM", "name" => "Turkmenistan" },
"796" => { "alpha-3-code" => "TCA", "alpha-2-code" => "TC", "name" => "Turks and Caicos Islands" },
"798" => { "alpha-3-code" => "TUV", "alpha-2-code" => "TV", "name" => "Tuvalu" },
"800" => { "alpha-3-code" => "UGA", "alpha-2-code" => "UG", "name" => "Uganda" },
"804" => { "alpha-3-code" => "UKR", "alpha-2-code" => "UA", "name" => "Ukraine" },
"784" => { "alpha-3-code" => "ARE", "alpha-2-code" => "AE", "name" => "United Arab Emirates" },
"826" => { "alpha-3-code" => "GBR", "alpha-2-code" => "GB", "name" => "United Kingdom" },
"840" => { "alpha-3-code" => "USA", "alpha-2-code" => "US", "name" => "United States" },
"581" => { "alpha-3-code" => "UMI", "alpha-2-code" => "UM", "name" => "United States Minor Outlying Islands" },
"858" => { "alpha-3-code" => "URY", "alpha-2-code" => "UY", "name" => "Uruguay" },
"860" => { "alpha-3-code" => "UZB", "alpha-2-code" => "UZ", "name" => "Uzbekistan" },
"548" => { "alpha-3-code" => "VUT", "alpha-2-code" => "VU", "name" => "Vanuatu" },
"862" => { "alpha-3-code" => "VEN", "alpha-2-code" => "VE", "name" => "Venezuela, Bolivarian Republic of" },
"704" => { "alpha-3-code" => "VNM", "alpha-2-code" => "VN", "name" => "Viet Nam" },
"092" => { "alpha-3-code" => "VGB", "alpha-2-code" => "VG", "name" => "Virgin Islands, British" },
"850" => { "alpha-3-code" => "VIR", "alpha-2-code" => "VI", "name" => "Virgin Islands, U.S." },
"876" => { "alpha-3-code" => "WLF", "alpha-2-code" => "WF", "name" => "Wallis and Futuna" },
"732" => { "alpha-3-code" => "ESH", "alpha-2-code" => "EH", "name" => "Western Sahara" },
"887" => { "alpha-3-code" => "YEM", "alpha-2-code" => "YE", "name" => "Yemen" },
"894" => { "alpha-3-code" => "ZMB", "alpha-2-code" => "ZM", "name" => "Zambia" },
"716" => { "alpha-3-code" => "ZWE", "alpha-2-code" => "ZW", "name" => "Zimbabwe" },
}
@reiz

This comment has been minimized.

Copy link
Owner Author

@reiz reiz commented May 31, 2014

This is a countries hash map with the numeric value as key. This hash map is extracted from this source http://en.wikipedia.org/wiki/ISO_3166-1.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment