@@ -0,0 +1,1796 @@
1+module Data.Country where
2+
3+import Prelude
4+
5+import Control.Monad.Except (throwError)
6+import Data.Enum (class Enum, class BoundedEnum, Cardinality(..), enumFromTo)
7+import Data.Maybe (Maybe(..))
8+import Foreign (ForeignError(..))
9+import Yoga.JSON (class ReadForeign, class WriteForeign, readImpl, writeImpl)
10+
11+data Country
12+ = Andorra
13+ | UnitedArabEmirates
14+ | Afghanistan
15+ | AntiguaAndBarbuda
16+ | Anguilla
17+ | Albania
18+ | Armenia
19+ | Angola
20+ | Antarctica
21+ | Argentina
22+ | AmericanSamoa
23+ | Austria
24+ | Australia
25+ | Aruba
26+ | AlandIslands
27+ | Azerbaijan
28+ | BosniaAndHerzegovina
29+ | Barbados
30+ | Bangladesh
31+ | Belgium
32+ | BurkinaFaso
33+ | Bulgaria
34+ | Bahrain
35+ | Burundi
36+ | Benin
37+ | SaintBarthelemy
38+ | Bermuda
39+ | BruneiDarussalam
40+ | BoliviaPlurinationalStateOf
41+ | BonaireSintEustatiusAndSaba
42+ | Brazil
43+ | Bahamas
44+ | Bhutan
45+ | BouvetIsland
46+ | Botswana
47+ | Belarus
48+ | Belize
49+ | Canada
50+ | CocosKeelingIslands
51+ | CongoDemocraticRepublicOfThe
52+ | CentralAfricanRepublic
53+ | Congo
54+ | Switzerland
55+ | CoteDIvoire
56+ | CookIslands
57+ | Chile
58+ | Cameroon
59+ | China
60+ | Colombia
61+ | CostaRica
62+ | Cuba
63+ | CaboVerde
64+ | Curacao
65+ | ChristmasIsland
66+ | Cyprus
67+ | Czechia
68+ | Germany
69+ | Djibouti
70+ | Denmark
71+ | Dominica
72+ | DominicanRepublic
73+ | Algeria
74+ | Ecuador
75+ | Estonia
76+ | Egypt
77+ | WesternSahara
78+ | Eritrea
79+ | Spain
80+ | Ethiopia
81+ | Finland
82+ | Fiji
83+ | FalklandIslandsMalvinas
84+ | MicronesiaFederatedStatesOf
85+ | FaroeIslands
86+ | France
87+ | Gabon
88+ | UnitedKingdomOfGreatBritainAndNorthernIreland
89+ | Grenada
90+ | Georgia
91+ | FrenchGuiana
92+ | Guernsey
93+ | Ghana
94+ | Gibraltar
95+ | Greenland
96+ | Gambia
97+ | Guinea
98+ | Guadeloupe
99+ | EquatorialGuinea
100+ | Greece
101+ | SouthGeorgiaAndTheSouthSandwichIslands
102+ | Guatemala
103+ | Guam
104+ | GuineaBissau
105+ | Guyana
106+ | HongKong
107+ | HeardIslandAndMcdonaldIslands
108+ | Honduras
109+ | Croatia
110+ | Haiti
111+ | Hungary
112+ | Indonesia
113+ | Ireland
114+ | Israel
115+ | IsleOfMan
116+ | India
117+ | BritishIndianOceanTerritory
118+ | Iraq
119+ | IranIslamicRepublicOf
120+ | Iceland
121+ | Italy
122+ | Jersey
123+ | Jamaica
124+ | Jordan
125+ | Japan
126+ | Kenya
127+ | Kyrgyzstan
128+ | Cambodia
129+ | Kiribati
130+ | Comoros
131+ | SaintKittsAndNevis
132+ | KoreaDemocraticPeopleSRepublicOf
133+ | KoreaRepublicOf
134+ | Kuwait
135+ | CaymanIslands
136+ | Kazakhstan
137+ | LaoPeopleSDemocraticRepublic
138+ | Lebanon
139+ | SaintLucia
140+ | Liechtenstein
141+ | SriLanka
142+ | Liberia
143+ | Lesotho
144+ | Lithuania
145+ | Luxembourg
146+ | Latvia
147+ | Libya
148+ | Morocco
149+ | Monaco
150+ | MoldovaRepublicOf
151+ | Montenegro
152+ | SaintMartinFrenchPart
153+ | Madagascar
154+ | MarshallIslands
155+ | NorthMacedonia
156+ | Mali
157+ | Myanmar
158+ | Mongolia
159+ | Macao
160+ | NorthernMarianaIslands
161+ | Martinique
162+ | Mauritania
163+ | Montserrat
164+ | Malta
165+ | Mauritius
166+ | Maldives
167+ | Malawi
168+ | Mexico
169+ | Malaysia
170+ | Mozambique
171+ | Namibia
172+ | NewCaledonia
173+ | Niger
174+ | NorfolkIsland
175+ | Nigeria
176+ | Nicaragua
177+ | NetherlandsKingdomOfThe
178+ | Norway
179+ | Nepal
180+ | Nauru
181+ | Niue
182+ | NewZealand
183+ | Oman
184+ | Panama
185+ | Peru
186+ | FrenchPolynesia
187+ | PapuaNewGuinea
188+ | Philippines
189+ | Pakistan
190+ | Poland
191+ | SaintPierreAndMiquelon
192+ | Pitcairn
193+ | PuertoRico
194+ | PalestineStateOf
195+ | Portugal
196+ | Palau
197+ | Paraguay
198+ | Qatar
199+ | Reunion
200+ | Romania
201+ | Serbia
202+ | RussianFederation
203+ | Rwanda
204+ | SaudiArabia
205+ | SolomonIslands
206+ | Seychelles
207+ | Sudan
208+ | Sweden
209+ | Singapore
210+ | SaintHelenaAscensionAndTristanDaCunha
211+ | Slovenia
212+ | SvalbardAndJanMayen
213+ | Slovakia
214+ | SierraLeone
215+ | SanMarino
216+ | Senegal
217+ | Somalia
218+ | Suriname
219+ | SouthSudan
220+ | SaoTomeAndPrincipe
221+ | ElSalvador
222+ | SintMaartenDutchPart
223+ | SyrianArabRepublic
224+ | Eswatini
225+ | TurksAndCaicosIslands
226+ | Chad
227+ | FrenchSouthernTerritories
228+ | Togo
229+ | Thailand
230+ | Tajikistan
231+ | Tokelau
232+ | TimorLeste
233+ | Turkmenistan
234+ | Tunisia
235+ | Tonga
236+ | Turkiye
237+ | TrinidadAndTobago
238+ | Tuvalu
239+ | TaiwanProvinceOfChina
240+ | TanzaniaUnitedRepublicOf
241+ | Ukraine
242+ | Uganda
243+ | UnitedStatesMinorOutlyingIslands
244+ | UnitedStatesOfAmerica
245+ | Uruguay
246+ | Uzbekistan
247+ | HolySee
248+ | SaintVincentAndTheGrenadines
249+ | VenezuelaBolivarianRepublicOf
250+ | VirginIslandsBritish
251+ | VirginIslandsUS
252+ | VietNam
253+ | Vanuatu
254+ | WallisAndFutuna
255+ | Samoa
256+ | Yemen
257+ | Mayotte
258+ | SouthAfrica
259+ | Zambia
260+ | Zimbabwe
261+
262+derive instance Eq Country
263+derive instance Ord Country
264+
265+instance Show Country where
266+ show = toAlpha2
267+
268+instance Bounded Country where
269+ bottom = Andorra
270+ top = Zimbabwe
271+
272+instance Enum Country where
273+ succ = case _ of
274+ Andorra -> Just UnitedArabEmirates
275+ UnitedArabEmirates -> Just Afghanistan
276+ Afghanistan -> Just AntiguaAndBarbuda
277+ AntiguaAndBarbuda -> Just Anguilla
278+ Anguilla -> Just Albania
279+ Albania -> Just Armenia
280+ Armenia -> Just Angola
281+ Angola -> Just Antarctica
282+ Antarctica -> Just Argentina
283+ Argentina -> Just AmericanSamoa
284+ AmericanSamoa -> Just Austria
285+ Austria -> Just Australia
286+ Australia -> Just Aruba
287+ Aruba -> Just AlandIslands
288+ AlandIslands -> Just Azerbaijan
289+ Azerbaijan -> Just BosniaAndHerzegovina
290+ BosniaAndHerzegovina -> Just Barbados
291+ Barbados -> Just Bangladesh
292+ Bangladesh -> Just Belgium
293+ Belgium -> Just BurkinaFaso
294+ BurkinaFaso -> Just Bulgaria
295+ Bulgaria -> Just Bahrain
296+ Bahrain -> Just Burundi
297+ Burundi -> Just Benin
298+ Benin -> Just SaintBarthelemy
299+ SaintBarthelemy -> Just Bermuda
300+ Bermuda -> Just BruneiDarussalam
301+ BruneiDarussalam -> Just BoliviaPlurinationalStateOf
302+ BoliviaPlurinationalStateOf -> Just BonaireSintEustatiusAndSaba
303+ BonaireSintEustatiusAndSaba -> Just Brazil
304+ Brazil -> Just Bahamas
305+ Bahamas -> Just Bhutan
306+ Bhutan -> Just BouvetIsland
307+ BouvetIsland -> Just Botswana
308+ Botswana -> Just Belarus
309+ Belarus -> Just Belize
310+ Belize -> Just Canada
311+ Canada -> Just CocosKeelingIslands
312+ CocosKeelingIslands -> Just CongoDemocraticRepublicOfThe
313+ CongoDemocraticRepublicOfThe -> Just CentralAfricanRepublic
314+ CentralAfricanRepublic -> Just Congo
315+ Congo -> Just Switzerland
316+ Switzerland -> Just CoteDIvoire
317+ CoteDIvoire -> Just CookIslands
318+ CookIslands -> Just Chile
319+ Chile -> Just Cameroon
320+ Cameroon -> Just China
321+ China -> Just Colombia
322+ Colombia -> Just CostaRica
323+ CostaRica -> Just Cuba
324+ Cuba -> Just CaboVerde
325+ CaboVerde -> Just Curacao
326+ Curacao -> Just ChristmasIsland
327+ ChristmasIsland -> Just Cyprus
328+ Cyprus -> Just Czechia
329+ Czechia -> Just Germany
330+ Germany -> Just Djibouti
331+ Djibouti -> Just Denmark
332+ Denmark -> Just Dominica
333+ Dominica -> Just DominicanRepublic
334+ DominicanRepublic -> Just Algeria
335+ Algeria -> Just Ecuador
336+ Ecuador -> Just Estonia
337+ Estonia -> Just Egypt
338+ Egypt -> Just WesternSahara
339+ WesternSahara -> Just Eritrea
340+ Eritrea -> Just Spain
341+ Spain -> Just Ethiopia
342+ Ethiopia -> Just Finland
343+ Finland -> Just Fiji
344+ Fiji -> Just FalklandIslandsMalvinas
345+ FalklandIslandsMalvinas -> Just MicronesiaFederatedStatesOf
346+ MicronesiaFederatedStatesOf -> Just FaroeIslands
347+ FaroeIslands -> Just France
348+ France -> Just Gabon
349+ Gabon -> Just UnitedKingdomOfGreatBritainAndNorthernIreland
350+ UnitedKingdomOfGreatBritainAndNorthernIreland -> Just Grenada
351+ Grenada -> Just Georgia
352+ Georgia -> Just FrenchGuiana
353+ FrenchGuiana -> Just Guernsey
354+ Guernsey -> Just Ghana
355+ Ghana -> Just Gibraltar
356+ Gibraltar -> Just Greenland
357+ Greenland -> Just Gambia
358+ Gambia -> Just Guinea
359+ Guinea -> Just Guadeloupe
360+ Guadeloupe -> Just EquatorialGuinea
361+ EquatorialGuinea -> Just Greece
362+ Greece -> Just SouthGeorgiaAndTheSouthSandwichIslands
363+ SouthGeorgiaAndTheSouthSandwichIslands -> Just Guatemala
364+ Guatemala -> Just Guam
365+ Guam -> Just GuineaBissau
366+ GuineaBissau -> Just Guyana
367+ Guyana -> Just HongKong
368+ HongKong -> Just HeardIslandAndMcdonaldIslands
369+ HeardIslandAndMcdonaldIslands -> Just Honduras
370+ Honduras -> Just Croatia
371+ Croatia -> Just Haiti
372+ Haiti -> Just Hungary
373+ Hungary -> Just Indonesia
374+ Indonesia -> Just Ireland
375+ Ireland -> Just Israel
376+ Israel -> Just IsleOfMan
377+ IsleOfMan -> Just India
378+ India -> Just BritishIndianOceanTerritory
379+ BritishIndianOceanTerritory -> Just Iraq
380+ Iraq -> Just IranIslamicRepublicOf
381+ IranIslamicRepublicOf -> Just Iceland
382+ Iceland -> Just Italy
383+ Italy -> Just Jersey
384+ Jersey -> Just Jamaica
385+ Jamaica -> Just Jordan
386+ Jordan -> Just Japan
387+ Japan -> Just Kenya
388+ Kenya -> Just Kyrgyzstan
389+ Kyrgyzstan -> Just Cambodia
390+ Cambodia -> Just Kiribati
391+ Kiribati -> Just Comoros
392+ Comoros -> Just SaintKittsAndNevis
393+ SaintKittsAndNevis -> Just KoreaDemocraticPeopleSRepublicOf
394+ KoreaDemocraticPeopleSRepublicOf -> Just KoreaRepublicOf
395+ KoreaRepublicOf -> Just Kuwait
396+ Kuwait -> Just CaymanIslands
397+ CaymanIslands -> Just Kazakhstan
398+ Kazakhstan -> Just LaoPeopleSDemocraticRepublic
399+ LaoPeopleSDemocraticRepublic -> Just Lebanon
400+ Lebanon -> Just SaintLucia
401+ SaintLucia -> Just Liechtenstein
402+ Liechtenstein -> Just SriLanka
403+ SriLanka -> Just Liberia
404+ Liberia -> Just Lesotho
405+ Lesotho -> Just Lithuania
406+ Lithuania -> Just Luxembourg
407+ Luxembourg -> Just Latvia
408+ Latvia -> Just Libya
409+ Libya -> Just Morocco
410+ Morocco -> Just Monaco
411+ Monaco -> Just MoldovaRepublicOf
412+ MoldovaRepublicOf -> Just Montenegro
413+ Montenegro -> Just SaintMartinFrenchPart
414+ SaintMartinFrenchPart -> Just Madagascar
415+ Madagascar -> Just MarshallIslands
416+ MarshallIslands -> Just NorthMacedonia
417+ NorthMacedonia -> Just Mali
418+ Mali -> Just Myanmar
419+ Myanmar -> Just Mongolia
420+ Mongolia -> Just Macao
421+ Macao -> Just NorthernMarianaIslands
422+ NorthernMarianaIslands -> Just Martinique
423+ Martinique -> Just Mauritania
424+ Mauritania -> Just Montserrat
425+ Montserrat -> Just Malta
426+ Malta -> Just Mauritius
427+ Mauritius -> Just Maldives
428+ Maldives -> Just Malawi
429+ Malawi -> Just Mexico
430+ Mexico -> Just Malaysia
431+ Malaysia -> Just Mozambique
432+ Mozambique -> Just Namibia
433+ Namibia -> Just NewCaledonia
434+ NewCaledonia -> Just Niger
435+ Niger -> Just NorfolkIsland
436+ NorfolkIsland -> Just Nigeria
437+ Nigeria -> Just Nicaragua
438+ Nicaragua -> Just NetherlandsKingdomOfThe
439+ NetherlandsKingdomOfThe -> Just Norway
440+ Norway -> Just Nepal
441+ Nepal -> Just Nauru
442+ Nauru -> Just Niue
443+ Niue -> Just NewZealand
444+ NewZealand -> Just Oman
445+ Oman -> Just Panama
446+ Panama -> Just Peru
447+ Peru -> Just FrenchPolynesia
448+ FrenchPolynesia -> Just PapuaNewGuinea
449+ PapuaNewGuinea -> Just Philippines
450+ Philippines -> Just Pakistan
451+ Pakistan -> Just Poland
452+ Poland -> Just SaintPierreAndMiquelon
453+ SaintPierreAndMiquelon -> Just Pitcairn
454+ Pitcairn -> Just PuertoRico
455+ PuertoRico -> Just PalestineStateOf
456+ PalestineStateOf -> Just Portugal
457+ Portugal -> Just Palau
458+ Palau -> Just Paraguay
459+ Paraguay -> Just Qatar
460+ Qatar -> Just Reunion
461+ Reunion -> Just Romania
462+ Romania -> Just Serbia
463+ Serbia -> Just RussianFederation
464+ RussianFederation -> Just Rwanda
465+ Rwanda -> Just SaudiArabia
466+ SaudiArabia -> Just SolomonIslands
467+ SolomonIslands -> Just Seychelles
468+ Seychelles -> Just Sudan
469+ Sudan -> Just Sweden
470+ Sweden -> Just Singapore
471+ Singapore -> Just SaintHelenaAscensionAndTristanDaCunha
472+ SaintHelenaAscensionAndTristanDaCunha -> Just Slovenia
473+ Slovenia -> Just SvalbardAndJanMayen
474+ SvalbardAndJanMayen -> Just Slovakia
475+ Slovakia -> Just SierraLeone
476+ SierraLeone -> Just SanMarino
477+ SanMarino -> Just Senegal
478+ Senegal -> Just Somalia
479+ Somalia -> Just Suriname
480+ Suriname -> Just SouthSudan
481+ SouthSudan -> Just SaoTomeAndPrincipe
482+ SaoTomeAndPrincipe -> Just ElSalvador
483+ ElSalvador -> Just SintMaartenDutchPart
484+ SintMaartenDutchPart -> Just SyrianArabRepublic
485+ SyrianArabRepublic -> Just Eswatini
486+ Eswatini -> Just TurksAndCaicosIslands
487+ TurksAndCaicosIslands -> Just Chad
488+ Chad -> Just FrenchSouthernTerritories
489+ FrenchSouthernTerritories -> Just Togo
490+ Togo -> Just Thailand
491+ Thailand -> Just Tajikistan
492+ Tajikistan -> Just Tokelau
493+ Tokelau -> Just TimorLeste
494+ TimorLeste -> Just Turkmenistan
495+ Turkmenistan -> Just Tunisia
496+ Tunisia -> Just Tonga
497+ Tonga -> Just Turkiye
498+ Turkiye -> Just TrinidadAndTobago
499+ TrinidadAndTobago -> Just Tuvalu
500+ Tuvalu -> Just TaiwanProvinceOfChina
501+ TaiwanProvinceOfChina -> Just TanzaniaUnitedRepublicOf
502+ TanzaniaUnitedRepublicOf -> Just Ukraine
503+ Ukraine -> Just Uganda
504+ Uganda -> Just UnitedStatesMinorOutlyingIslands
505+ UnitedStatesMinorOutlyingIslands -> Just UnitedStatesOfAmerica
506+ UnitedStatesOfAmerica -> Just Uruguay
507+ Uruguay -> Just Uzbekistan
508+ Uzbekistan -> Just HolySee
509+ HolySee -> Just SaintVincentAndTheGrenadines
510+ SaintVincentAndTheGrenadines -> Just VenezuelaBolivarianRepublicOf
511+ VenezuelaBolivarianRepublicOf -> Just VirginIslandsBritish
512+ VirginIslandsBritish -> Just VirginIslandsUS
513+ VirginIslandsUS -> Just VietNam
514+ VietNam -> Just Vanuatu
515+ Vanuatu -> Just WallisAndFutuna
516+ WallisAndFutuna -> Just Samoa
517+ Samoa -> Just Yemen
518+ Yemen -> Just Mayotte
519+ Mayotte -> Just SouthAfrica
520+ SouthAfrica -> Just Zambia
521+ Zambia -> Just Zimbabwe
522+ Zimbabwe -> Nothing
523+ pred = case _ of
524+ Andorra -> Nothing
525+ UnitedArabEmirates -> Just Andorra
526+ Afghanistan -> Just UnitedArabEmirates
527+ AntiguaAndBarbuda -> Just Afghanistan
528+ Anguilla -> Just AntiguaAndBarbuda
529+ Albania -> Just Anguilla
530+ Armenia -> Just Albania
531+ Angola -> Just Armenia
532+ Antarctica -> Just Angola
533+ Argentina -> Just Antarctica
534+ AmericanSamoa -> Just Argentina
535+ Austria -> Just AmericanSamoa
536+ Australia -> Just Austria
537+ Aruba -> Just Australia
538+ AlandIslands -> Just Aruba
539+ Azerbaijan -> Just AlandIslands
540+ BosniaAndHerzegovina -> Just Azerbaijan
541+ Barbados -> Just BosniaAndHerzegovina
542+ Bangladesh -> Just Barbados
543+ Belgium -> Just Bangladesh
544+ BurkinaFaso -> Just Belgium
545+ Bulgaria -> Just BurkinaFaso
546+ Bahrain -> Just Bulgaria
547+ Burundi -> Just Bahrain
548+ Benin -> Just Burundi
549+ SaintBarthelemy -> Just Benin
550+ Bermuda -> Just SaintBarthelemy
551+ BruneiDarussalam -> Just Bermuda
552+ BoliviaPlurinationalStateOf -> Just BruneiDarussalam
553+ BonaireSintEustatiusAndSaba -> Just BoliviaPlurinationalStateOf
554+ Brazil -> Just BonaireSintEustatiusAndSaba
555+ Bahamas -> Just Brazil
556+ Bhutan -> Just Bahamas
557+ BouvetIsland -> Just Bhutan
558+ Botswana -> Just BouvetIsland
559+ Belarus -> Just Botswana
560+ Belize -> Just Belarus
561+ Canada -> Just Belize
562+ CocosKeelingIslands -> Just Canada
563+ CongoDemocraticRepublicOfThe -> Just CocosKeelingIslands
564+ CentralAfricanRepublic -> Just CongoDemocraticRepublicOfThe
565+ Congo -> Just CentralAfricanRepublic
566+ Switzerland -> Just Congo
567+ CoteDIvoire -> Just Switzerland
568+ CookIslands -> Just CoteDIvoire
569+ Chile -> Just CookIslands
570+ Cameroon -> Just Chile
571+ China -> Just Cameroon
572+ Colombia -> Just China
573+ CostaRica -> Just Colombia
574+ Cuba -> Just CostaRica
575+ CaboVerde -> Just Cuba
576+ Curacao -> Just CaboVerde
577+ ChristmasIsland -> Just Curacao
578+ Cyprus -> Just ChristmasIsland
579+ Czechia -> Just Cyprus
580+ Germany -> Just Czechia
581+ Djibouti -> Just Germany
582+ Denmark -> Just Djibouti
583+ Dominica -> Just Denmark
584+ DominicanRepublic -> Just Dominica
585+ Algeria -> Just DominicanRepublic
586+ Ecuador -> Just Algeria
587+ Estonia -> Just Ecuador
588+ Egypt -> Just Estonia
589+ WesternSahara -> Just Egypt
590+ Eritrea -> Just WesternSahara
591+ Spain -> Just Eritrea
592+ Ethiopia -> Just Spain
593+ Finland -> Just Ethiopia
594+ Fiji -> Just Finland
595+ FalklandIslandsMalvinas -> Just Fiji
596+ MicronesiaFederatedStatesOf -> Just FalklandIslandsMalvinas
597+ FaroeIslands -> Just MicronesiaFederatedStatesOf
598+ France -> Just FaroeIslands
599+ Gabon -> Just France
600+ UnitedKingdomOfGreatBritainAndNorthernIreland -> Just Gabon
601+ Grenada -> Just UnitedKingdomOfGreatBritainAndNorthernIreland
602+ Georgia -> Just Grenada
603+ FrenchGuiana -> Just Georgia
604+ Guernsey -> Just FrenchGuiana
605+ Ghana -> Just Guernsey
606+ Gibraltar -> Just Ghana
607+ Greenland -> Just Gibraltar
608+ Gambia -> Just Greenland
609+ Guinea -> Just Gambia
610+ Guadeloupe -> Just Guinea
611+ EquatorialGuinea -> Just Guadeloupe
612+ Greece -> Just EquatorialGuinea
613+ SouthGeorgiaAndTheSouthSandwichIslands -> Just Greece
614+ Guatemala -> Just SouthGeorgiaAndTheSouthSandwichIslands
615+ Guam -> Just Guatemala
616+ GuineaBissau -> Just Guam
617+ Guyana -> Just GuineaBissau
618+ HongKong -> Just Guyana
619+ HeardIslandAndMcdonaldIslands -> Just HongKong
620+ Honduras -> Just HeardIslandAndMcdonaldIslands
621+ Croatia -> Just Honduras
622+ Haiti -> Just Croatia
623+ Hungary -> Just Haiti
624+ Indonesia -> Just Hungary
625+ Ireland -> Just Indonesia
626+ Israel -> Just Ireland
627+ IsleOfMan -> Just Israel
628+ India -> Just IsleOfMan
629+ BritishIndianOceanTerritory -> Just India
630+ Iraq -> Just BritishIndianOceanTerritory
631+ IranIslamicRepublicOf -> Just Iraq
632+ Iceland -> Just IranIslamicRepublicOf
633+ Italy -> Just Iceland
634+ Jersey -> Just Italy
635+ Jamaica -> Just Jersey
636+ Jordan -> Just Jamaica
637+ Japan -> Just Jordan
638+ Kenya -> Just Japan
639+ Kyrgyzstan -> Just Kenya
640+ Cambodia -> Just Kyrgyzstan
641+ Kiribati -> Just Cambodia
642+ Comoros -> Just Kiribati
643+ SaintKittsAndNevis -> Just Comoros
644+ KoreaDemocraticPeopleSRepublicOf -> Just SaintKittsAndNevis
645+ KoreaRepublicOf -> Just KoreaDemocraticPeopleSRepublicOf
646+ Kuwait -> Just KoreaRepublicOf
647+ CaymanIslands -> Just Kuwait
648+ Kazakhstan -> Just CaymanIslands
649+ LaoPeopleSDemocraticRepublic -> Just Kazakhstan
650+ Lebanon -> Just LaoPeopleSDemocraticRepublic
651+ SaintLucia -> Just Lebanon
652+ Liechtenstein -> Just SaintLucia
653+ SriLanka -> Just Liechtenstein
654+ Liberia -> Just SriLanka
655+ Lesotho -> Just Liberia
656+ Lithuania -> Just Lesotho
657+ Luxembourg -> Just Lithuania
658+ Latvia -> Just Luxembourg
659+ Libya -> Just Latvia
660+ Morocco -> Just Libya
661+ Monaco -> Just Morocco
662+ MoldovaRepublicOf -> Just Monaco
663+ Montenegro -> Just MoldovaRepublicOf
664+ SaintMartinFrenchPart -> Just Montenegro
665+ Madagascar -> Just SaintMartinFrenchPart
666+ MarshallIslands -> Just Madagascar
667+ NorthMacedonia -> Just MarshallIslands
668+ Mali -> Just NorthMacedonia
669+ Myanmar -> Just Mali
670+ Mongolia -> Just Myanmar
671+ Macao -> Just Mongolia
672+ NorthernMarianaIslands -> Just Macao
673+ Martinique -> Just NorthernMarianaIslands
674+ Mauritania -> Just Martinique
675+ Montserrat -> Just Mauritania
676+ Malta -> Just Montserrat
677+ Mauritius -> Just Malta
678+ Maldives -> Just Mauritius
679+ Malawi -> Just Maldives
680+ Mexico -> Just Malawi
681+ Malaysia -> Just Mexico
682+ Mozambique -> Just Malaysia
683+ Namibia -> Just Mozambique
684+ NewCaledonia -> Just Namibia
685+ Niger -> Just NewCaledonia
686+ NorfolkIsland -> Just Niger
687+ Nigeria -> Just NorfolkIsland
688+ Nicaragua -> Just Nigeria
689+ NetherlandsKingdomOfThe -> Just Nicaragua
690+ Norway -> Just NetherlandsKingdomOfThe
691+ Nepal -> Just Norway
692+ Nauru -> Just Nepal
693+ Niue -> Just Nauru
694+ NewZealand -> Just Niue
695+ Oman -> Just NewZealand
696+ Panama -> Just Oman
697+ Peru -> Just Panama
698+ FrenchPolynesia -> Just Peru
699+ PapuaNewGuinea -> Just FrenchPolynesia
700+ Philippines -> Just PapuaNewGuinea
701+ Pakistan -> Just Philippines
702+ Poland -> Just Pakistan
703+ SaintPierreAndMiquelon -> Just Poland
704+ Pitcairn -> Just SaintPierreAndMiquelon
705+ PuertoRico -> Just Pitcairn
706+ PalestineStateOf -> Just PuertoRico
707+ Portugal -> Just PalestineStateOf
708+ Palau -> Just Portugal
709+ Paraguay -> Just Palau
710+ Qatar -> Just Paraguay
711+ Reunion -> Just Qatar
712+ Romania -> Just Reunion
713+ Serbia -> Just Romania
714+ RussianFederation -> Just Serbia
715+ Rwanda -> Just RussianFederation
716+ SaudiArabia -> Just Rwanda
717+ SolomonIslands -> Just SaudiArabia
718+ Seychelles -> Just SolomonIslands
719+ Sudan -> Just Seychelles
720+ Sweden -> Just Sudan
721+ Singapore -> Just Sweden
722+ SaintHelenaAscensionAndTristanDaCunha -> Just Singapore
723+ Slovenia -> Just SaintHelenaAscensionAndTristanDaCunha
724+ SvalbardAndJanMayen -> Just Slovenia
725+ Slovakia -> Just SvalbardAndJanMayen
726+ SierraLeone -> Just Slovakia
727+ SanMarino -> Just SierraLeone
728+ Senegal -> Just SanMarino
729+ Somalia -> Just Senegal
730+ Suriname -> Just Somalia
731+ SouthSudan -> Just Suriname
732+ SaoTomeAndPrincipe -> Just SouthSudan
733+ ElSalvador -> Just SaoTomeAndPrincipe
734+ SintMaartenDutchPart -> Just ElSalvador
735+ SyrianArabRepublic -> Just SintMaartenDutchPart
736+ Eswatini -> Just SyrianArabRepublic
737+ TurksAndCaicosIslands -> Just Eswatini
738+ Chad -> Just TurksAndCaicosIslands
739+ FrenchSouthernTerritories -> Just Chad
740+ Togo -> Just FrenchSouthernTerritories
741+ Thailand -> Just Togo
742+ Tajikistan -> Just Thailand
743+ Tokelau -> Just Tajikistan
744+ TimorLeste -> Just Tokelau
745+ Turkmenistan -> Just TimorLeste
746+ Tunisia -> Just Turkmenistan
747+ Tonga -> Just Tunisia
748+ Turkiye -> Just Tonga
749+ TrinidadAndTobago -> Just Turkiye
750+ Tuvalu -> Just TrinidadAndTobago
751+ TaiwanProvinceOfChina -> Just Tuvalu
752+ TanzaniaUnitedRepublicOf -> Just TaiwanProvinceOfChina
753+ Ukraine -> Just TanzaniaUnitedRepublicOf
754+ Uganda -> Just Ukraine
755+ UnitedStatesMinorOutlyingIslands -> Just Uganda
756+ UnitedStatesOfAmerica -> Just UnitedStatesMinorOutlyingIslands
757+ Uruguay -> Just UnitedStatesOfAmerica
758+ Uzbekistan -> Just Uruguay
759+ HolySee -> Just Uzbekistan
760+ SaintVincentAndTheGrenadines -> Just HolySee
761+ VenezuelaBolivarianRepublicOf -> Just SaintVincentAndTheGrenadines
762+ VirginIslandsBritish -> Just VenezuelaBolivarianRepublicOf
763+ VirginIslandsUS -> Just VirginIslandsBritish
764+ VietNam -> Just VirginIslandsUS
765+ Vanuatu -> Just VietNam
766+ WallisAndFutuna -> Just Vanuatu
767+ Samoa -> Just WallisAndFutuna
768+ Yemen -> Just Samoa
769+ Mayotte -> Just Yemen
770+ SouthAfrica -> Just Mayotte
771+ Zambia -> Just SouthAfrica
772+ Zimbabwe -> Just Zambia
773+
774+instance BoundedEnum Country where
775+ cardinality = Cardinality 249
776+ toEnum = case _ of
777+ 0 -> Just Andorra
778+ 1 -> Just UnitedArabEmirates
779+ 2 -> Just Afghanistan
780+ 3 -> Just AntiguaAndBarbuda
781+ 4 -> Just Anguilla
782+ 5 -> Just Albania
783+ 6 -> Just Armenia
784+ 7 -> Just Angola
785+ 8 -> Just Antarctica
786+ 9 -> Just Argentina
787+ 10 -> Just AmericanSamoa
788+ 11 -> Just Austria
789+ 12 -> Just Australia
790+ 13 -> Just Aruba
791+ 14 -> Just AlandIslands
792+ 15 -> Just Azerbaijan
793+ 16 -> Just BosniaAndHerzegovina
794+ 17 -> Just Barbados
795+ 18 -> Just Bangladesh
796+ 19 -> Just Belgium
797+ 20 -> Just BurkinaFaso
798+ 21 -> Just Bulgaria
799+ 22 -> Just Bahrain
800+ 23 -> Just Burundi
801+ 24 -> Just Benin
802+ 25 -> Just SaintBarthelemy
803+ 26 -> Just Bermuda
804+ 27 -> Just BruneiDarussalam
805+ 28 -> Just BoliviaPlurinationalStateOf
806+ 29 -> Just BonaireSintEustatiusAndSaba
807+ 30 -> Just Brazil
808+ 31 -> Just Bahamas
809+ 32 -> Just Bhutan
810+ 33 -> Just BouvetIsland
811+ 34 -> Just Botswana
812+ 35 -> Just Belarus
813+ 36 -> Just Belize
814+ 37 -> Just Canada
815+ 38 -> Just CocosKeelingIslands
816+ 39 -> Just CongoDemocraticRepublicOfThe
817+ 40 -> Just CentralAfricanRepublic
818+ 41 -> Just Congo
819+ 42 -> Just Switzerland
820+ 43 -> Just CoteDIvoire
821+ 44 -> Just CookIslands
822+ 45 -> Just Chile
823+ 46 -> Just Cameroon
824+ 47 -> Just China
825+ 48 -> Just Colombia
826+ 49 -> Just CostaRica
827+ 50 -> Just Cuba
828+ 51 -> Just CaboVerde
829+ 52 -> Just Curacao
830+ 53 -> Just ChristmasIsland
831+ 54 -> Just Cyprus
832+ 55 -> Just Czechia
833+ 56 -> Just Germany
834+ 57 -> Just Djibouti
835+ 58 -> Just Denmark
836+ 59 -> Just Dominica
837+ 60 -> Just DominicanRepublic
838+ 61 -> Just Algeria
839+ 62 -> Just Ecuador
840+ 63 -> Just Estonia
841+ 64 -> Just Egypt
842+ 65 -> Just WesternSahara
843+ 66 -> Just Eritrea
844+ 67 -> Just Spain
845+ 68 -> Just Ethiopia
846+ 69 -> Just Finland
847+ 70 -> Just Fiji
848+ 71 -> Just FalklandIslandsMalvinas
849+ 72 -> Just MicronesiaFederatedStatesOf
850+ 73 -> Just FaroeIslands
851+ 74 -> Just France
852+ 75 -> Just Gabon
853+ 76 -> Just UnitedKingdomOfGreatBritainAndNorthernIreland
854+ 77 -> Just Grenada
855+ 78 -> Just Georgia
856+ 79 -> Just FrenchGuiana
857+ 80 -> Just Guernsey
858+ 81 -> Just Ghana
859+ 82 -> Just Gibraltar
860+ 83 -> Just Greenland
861+ 84 -> Just Gambia
862+ 85 -> Just Guinea
863+ 86 -> Just Guadeloupe
864+ 87 -> Just EquatorialGuinea
865+ 88 -> Just Greece
866+ 89 -> Just SouthGeorgiaAndTheSouthSandwichIslands
867+ 90 -> Just Guatemala
868+ 91 -> Just Guam
869+ 92 -> Just GuineaBissau
870+ 93 -> Just Guyana
871+ 94 -> Just HongKong
872+ 95 -> Just HeardIslandAndMcdonaldIslands
873+ 96 -> Just Honduras
874+ 97 -> Just Croatia
875+ 98 -> Just Haiti
876+ 99 -> Just Hungary
877+ 100 -> Just Indonesia
878+ 101 -> Just Ireland
879+ 102 -> Just Israel
880+ 103 -> Just IsleOfMan
881+ 104 -> Just India
882+ 105 -> Just BritishIndianOceanTerritory
883+ 106 -> Just Iraq
884+ 107 -> Just IranIslamicRepublicOf
885+ 108 -> Just Iceland
886+ 109 -> Just Italy
887+ 110 -> Just Jersey
888+ 111 -> Just Jamaica
889+ 112 -> Just Jordan
890+ 113 -> Just Japan
891+ 114 -> Just Kenya
892+ 115 -> Just Kyrgyzstan
893+ 116 -> Just Cambodia
894+ 117 -> Just Kiribati
895+ 118 -> Just Comoros
896+ 119 -> Just SaintKittsAndNevis
897+ 120 -> Just KoreaDemocraticPeopleSRepublicOf
898+ 121 -> Just KoreaRepublicOf
899+ 122 -> Just Kuwait
900+ 123 -> Just CaymanIslands
901+ 124 -> Just Kazakhstan
902+ 125 -> Just LaoPeopleSDemocraticRepublic
903+ 126 -> Just Lebanon
904+ 127 -> Just SaintLucia
905+ 128 -> Just Liechtenstein
906+ 129 -> Just SriLanka
907+ 130 -> Just Liberia
908+ 131 -> Just Lesotho
909+ 132 -> Just Lithuania
910+ 133 -> Just Luxembourg
911+ 134 -> Just Latvia
912+ 135 -> Just Libya
913+ 136 -> Just Morocco
914+ 137 -> Just Monaco
915+ 138 -> Just MoldovaRepublicOf
916+ 139 -> Just Montenegro
917+ 140 -> Just SaintMartinFrenchPart
918+ 141 -> Just Madagascar
919+ 142 -> Just MarshallIslands
920+ 143 -> Just NorthMacedonia
921+ 144 -> Just Mali
922+ 145 -> Just Myanmar
923+ 146 -> Just Mongolia
924+ 147 -> Just Macao
925+ 148 -> Just NorthernMarianaIslands
926+ 149 -> Just Martinique
927+ 150 -> Just Mauritania
928+ 151 -> Just Montserrat
929+ 152 -> Just Malta
930+ 153 -> Just Mauritius
931+ 154 -> Just Maldives
932+ 155 -> Just Malawi
933+ 156 -> Just Mexico
934+ 157 -> Just Malaysia
935+ 158 -> Just Mozambique
936+ 159 -> Just Namibia
937+ 160 -> Just NewCaledonia
938+ 161 -> Just Niger
939+ 162 -> Just NorfolkIsland
940+ 163 -> Just Nigeria
941+ 164 -> Just Nicaragua
942+ 165 -> Just NetherlandsKingdomOfThe
943+ 166 -> Just Norway
944+ 167 -> Just Nepal
945+ 168 -> Just Nauru
946+ 169 -> Just Niue
947+ 170 -> Just NewZealand
948+ 171 -> Just Oman
949+ 172 -> Just Panama
950+ 173 -> Just Peru
951+ 174 -> Just FrenchPolynesia
952+ 175 -> Just PapuaNewGuinea
953+ 176 -> Just Philippines
954+ 177 -> Just Pakistan
955+ 178 -> Just Poland
956+ 179 -> Just SaintPierreAndMiquelon
957+ 180 -> Just Pitcairn
958+ 181 -> Just PuertoRico
959+ 182 -> Just PalestineStateOf
960+ 183 -> Just Portugal
961+ 184 -> Just Palau
962+ 185 -> Just Paraguay
963+ 186 -> Just Qatar
964+ 187 -> Just Reunion
965+ 188 -> Just Romania
966+ 189 -> Just Serbia
967+ 190 -> Just RussianFederation
968+ 191 -> Just Rwanda
969+ 192 -> Just SaudiArabia
970+ 193 -> Just SolomonIslands
971+ 194 -> Just Seychelles
972+ 195 -> Just Sudan
973+ 196 -> Just Sweden
974+ 197 -> Just Singapore
975+ 198 -> Just SaintHelenaAscensionAndTristanDaCunha
976+ 199 -> Just Slovenia
977+ 200 -> Just SvalbardAndJanMayen
978+ 201 -> Just Slovakia
979+ 202 -> Just SierraLeone
980+ 203 -> Just SanMarino
981+ 204 -> Just Senegal
982+ 205 -> Just Somalia
983+ 206 -> Just Suriname
984+ 207 -> Just SouthSudan
985+ 208 -> Just SaoTomeAndPrincipe
986+ 209 -> Just ElSalvador
987+ 210 -> Just SintMaartenDutchPart
988+ 211 -> Just SyrianArabRepublic
989+ 212 -> Just Eswatini
990+ 213 -> Just TurksAndCaicosIslands
991+ 214 -> Just Chad
992+ 215 -> Just FrenchSouthernTerritories
993+ 216 -> Just Togo
994+ 217 -> Just Thailand
995+ 218 -> Just Tajikistan
996+ 219 -> Just Tokelau
997+ 220 -> Just TimorLeste
998+ 221 -> Just Turkmenistan
999+ 222 -> Just Tunisia
1000+ 223 -> Just Tonga
1001+ 224 -> Just Turkiye
1002+ 225 -> Just TrinidadAndTobago
1003+ 226 -> Just Tuvalu
1004+ 227 -> Just TaiwanProvinceOfChina
1005+ 228 -> Just TanzaniaUnitedRepublicOf
1006+ 229 -> Just Ukraine
1007+ 230 -> Just Uganda
1008+ 231 -> Just UnitedStatesMinorOutlyingIslands
1009+ 232 -> Just UnitedStatesOfAmerica
1010+ 233 -> Just Uruguay
1011+ 234 -> Just Uzbekistan
1012+ 235 -> Just HolySee
1013+ 236 -> Just SaintVincentAndTheGrenadines
1014+ 237 -> Just VenezuelaBolivarianRepublicOf
1015+ 238 -> Just VirginIslandsBritish
1016+ 239 -> Just VirginIslandsUS
1017+ 240 -> Just VietNam
1018+ 241 -> Just Vanuatu
1019+ 242 -> Just WallisAndFutuna
1020+ 243 -> Just Samoa
1021+ 244 -> Just Yemen
1022+ 245 -> Just Mayotte
1023+ 246 -> Just SouthAfrica
1024+ 247 -> Just Zambia
1025+ 248 -> Just Zimbabwe
1026+ _ -> Nothing
1027+ fromEnum = case _ of
1028+ Andorra -> 0
1029+ UnitedArabEmirates -> 1
1030+ Afghanistan -> 2
1031+ AntiguaAndBarbuda -> 3
1032+ Anguilla -> 4
1033+ Albania -> 5
1034+ Armenia -> 6
1035+ Angola -> 7
1036+ Antarctica -> 8
1037+ Argentina -> 9
1038+ AmericanSamoa -> 10
1039+ Austria -> 11
1040+ Australia -> 12
1041+ Aruba -> 13
1042+ AlandIslands -> 14
1043+ Azerbaijan -> 15
1044+ BosniaAndHerzegovina -> 16
1045+ Barbados -> 17
1046+ Bangladesh -> 18
1047+ Belgium -> 19
1048+ BurkinaFaso -> 20
1049+ Bulgaria -> 21
1050+ Bahrain -> 22
1051+ Burundi -> 23
1052+ Benin -> 24
1053+ SaintBarthelemy -> 25
1054+ Bermuda -> 26
1055+ BruneiDarussalam -> 27
1056+ BoliviaPlurinationalStateOf -> 28
1057+ BonaireSintEustatiusAndSaba -> 29
1058+ Brazil -> 30
1059+ Bahamas -> 31
1060+ Bhutan -> 32
1061+ BouvetIsland -> 33
1062+ Botswana -> 34
1063+ Belarus -> 35
1064+ Belize -> 36
1065+ Canada -> 37
1066+ CocosKeelingIslands -> 38
1067+ CongoDemocraticRepublicOfThe -> 39
1068+ CentralAfricanRepublic -> 40
1069+ Congo -> 41
1070+ Switzerland -> 42
1071+ CoteDIvoire -> 43
1072+ CookIslands -> 44
1073+ Chile -> 45
1074+ Cameroon -> 46
1075+ China -> 47
1076+ Colombia -> 48
1077+ CostaRica -> 49
1078+ Cuba -> 50
1079+ CaboVerde -> 51
1080+ Curacao -> 52
1081+ ChristmasIsland -> 53
1082+ Cyprus -> 54
1083+ Czechia -> 55
1084+ Germany -> 56
1085+ Djibouti -> 57
1086+ Denmark -> 58
1087+ Dominica -> 59
1088+ DominicanRepublic -> 60
1089+ Algeria -> 61
1090+ Ecuador -> 62
1091+ Estonia -> 63
1092+ Egypt -> 64
1093+ WesternSahara -> 65
1094+ Eritrea -> 66
1095+ Spain -> 67
1096+ Ethiopia -> 68
1097+ Finland -> 69
1098+ Fiji -> 70
1099+ FalklandIslandsMalvinas -> 71
1100+ MicronesiaFederatedStatesOf -> 72
1101+ FaroeIslands -> 73
1102+ France -> 74
1103+ Gabon -> 75
1104+ UnitedKingdomOfGreatBritainAndNorthernIreland -> 76
1105+ Grenada -> 77
1106+ Georgia -> 78
1107+ FrenchGuiana -> 79
1108+ Guernsey -> 80
1109+ Ghana -> 81
1110+ Gibraltar -> 82
1111+ Greenland -> 83
1112+ Gambia -> 84
1113+ Guinea -> 85
1114+ Guadeloupe -> 86
1115+ EquatorialGuinea -> 87
1116+ Greece -> 88
1117+ SouthGeorgiaAndTheSouthSandwichIslands -> 89
1118+ Guatemala -> 90
1119+ Guam -> 91
1120+ GuineaBissau -> 92
1121+ Guyana -> 93
1122+ HongKong -> 94
1123+ HeardIslandAndMcdonaldIslands -> 95
1124+ Honduras -> 96
1125+ Croatia -> 97
1126+ Haiti -> 98
1127+ Hungary -> 99
1128+ Indonesia -> 100
1129+ Ireland -> 101
1130+ Israel -> 102
1131+ IsleOfMan -> 103
1132+ India -> 104
1133+ BritishIndianOceanTerritory -> 105
1134+ Iraq -> 106
1135+ IranIslamicRepublicOf -> 107
1136+ Iceland -> 108
1137+ Italy -> 109
1138+ Jersey -> 110
1139+ Jamaica -> 111
1140+ Jordan -> 112
1141+ Japan -> 113
1142+ Kenya -> 114
1143+ Kyrgyzstan -> 115
1144+ Cambodia -> 116
1145+ Kiribati -> 117
1146+ Comoros -> 118
1147+ SaintKittsAndNevis -> 119
1148+ KoreaDemocraticPeopleSRepublicOf -> 120
1149+ KoreaRepublicOf -> 121
1150+ Kuwait -> 122
1151+ CaymanIslands -> 123
1152+ Kazakhstan -> 124
1153+ LaoPeopleSDemocraticRepublic -> 125
1154+ Lebanon -> 126
1155+ SaintLucia -> 127
1156+ Liechtenstein -> 128
1157+ SriLanka -> 129
1158+ Liberia -> 130
1159+ Lesotho -> 131
1160+ Lithuania -> 132
1161+ Luxembourg -> 133
1162+ Latvia -> 134
1163+ Libya -> 135
1164+ Morocco -> 136
1165+ Monaco -> 137
1166+ MoldovaRepublicOf -> 138
1167+ Montenegro -> 139
1168+ SaintMartinFrenchPart -> 140
1169+ Madagascar -> 141
1170+ MarshallIslands -> 142
1171+ NorthMacedonia -> 143
1172+ Mali -> 144
1173+ Myanmar -> 145
1174+ Mongolia -> 146
1175+ Macao -> 147
1176+ NorthernMarianaIslands -> 148
1177+ Martinique -> 149
1178+ Mauritania -> 150
1179+ Montserrat -> 151
1180+ Malta -> 152
1181+ Mauritius -> 153
1182+ Maldives -> 154
1183+ Malawi -> 155
1184+ Mexico -> 156
1185+ Malaysia -> 157
1186+ Mozambique -> 158
1187+ Namibia -> 159
1188+ NewCaledonia -> 160
1189+ Niger -> 161
1190+ NorfolkIsland -> 162
1191+ Nigeria -> 163
1192+ Nicaragua -> 164
1193+ NetherlandsKingdomOfThe -> 165
1194+ Norway -> 166
1195+ Nepal -> 167
1196+ Nauru -> 168
1197+ Niue -> 169
1198+ NewZealand -> 170
1199+ Oman -> 171
1200+ Panama -> 172
1201+ Peru -> 173
1202+ FrenchPolynesia -> 174
1203+ PapuaNewGuinea -> 175
1204+ Philippines -> 176
1205+ Pakistan -> 177
1206+ Poland -> 178
1207+ SaintPierreAndMiquelon -> 179
1208+ Pitcairn -> 180
1209+ PuertoRico -> 181
1210+ PalestineStateOf -> 182
1211+ Portugal -> 183
1212+ Palau -> 184
1213+ Paraguay -> 185
1214+ Qatar -> 186
1215+ Reunion -> 187
1216+ Romania -> 188
1217+ Serbia -> 189
1218+ RussianFederation -> 190
1219+ Rwanda -> 191
1220+ SaudiArabia -> 192
1221+ SolomonIslands -> 193
1222+ Seychelles -> 194
1223+ Sudan -> 195
1224+ Sweden -> 196
1225+ Singapore -> 197
1226+ SaintHelenaAscensionAndTristanDaCunha -> 198
1227+ Slovenia -> 199
1228+ SvalbardAndJanMayen -> 200
1229+ Slovakia -> 201
1230+ SierraLeone -> 202
1231+ SanMarino -> 203
1232+ Senegal -> 204
1233+ Somalia -> 205
1234+ Suriname -> 206
1235+ SouthSudan -> 207
1236+ SaoTomeAndPrincipe -> 208
1237+ ElSalvador -> 209
1238+ SintMaartenDutchPart -> 210
1239+ SyrianArabRepublic -> 211
1240+ Eswatini -> 212
1241+ TurksAndCaicosIslands -> 213
1242+ Chad -> 214
1243+ FrenchSouthernTerritories -> 215
1244+ Togo -> 216
1245+ Thailand -> 217
1246+ Tajikistan -> 218
1247+ Tokelau -> 219
1248+ TimorLeste -> 220
1249+ Turkmenistan -> 221
1250+ Tunisia -> 222
1251+ Tonga -> 223
1252+ Turkiye -> 224
1253+ TrinidadAndTobago -> 225
1254+ Tuvalu -> 226
1255+ TaiwanProvinceOfChina -> 227
1256+ TanzaniaUnitedRepublicOf -> 228
1257+ Ukraine -> 229
1258+ Uganda -> 230
1259+ UnitedStatesMinorOutlyingIslands -> 231
1260+ UnitedStatesOfAmerica -> 232
1261+ Uruguay -> 233
1262+ Uzbekistan -> 234
1263+ HolySee -> 235
1264+ SaintVincentAndTheGrenadines -> 236
1265+ VenezuelaBolivarianRepublicOf -> 237
1266+ VirginIslandsBritish -> 238
1267+ VirginIslandsUS -> 239
1268+ VietNam -> 240
1269+ Vanuatu -> 241
1270+ WallisAndFutuna -> 242
1271+ Samoa -> 243
1272+ Yemen -> 244
1273+ Mayotte -> 245
1274+ SouthAfrica -> 246
1275+ Zambia -> 247
1276+ Zimbabwe -> 248
1277+
1278+toAlpha2 :: Country -> String
1279+toAlpha2 = case _ of
1280+ Andorra -> "AD"
1281+ UnitedArabEmirates -> "AE"
1282+ Afghanistan -> "AF"
1283+ AntiguaAndBarbuda -> "AG"
1284+ Anguilla -> "AI"
1285+ Albania -> "AL"
1286+ Armenia -> "AM"
1287+ Angola -> "AO"
1288+ Antarctica -> "AQ"
1289+ Argentina -> "AR"
1290+ AmericanSamoa -> "AS"
1291+ Austria -> "AT"
1292+ Australia -> "AU"
1293+ Aruba -> "AW"
1294+ AlandIslands -> "AX"
1295+ Azerbaijan -> "AZ"
1296+ BosniaAndHerzegovina -> "BA"
1297+ Barbados -> "BB"
1298+ Bangladesh -> "BD"
1299+ Belgium -> "BE"
1300+ BurkinaFaso -> "BF"
1301+ Bulgaria -> "BG"
1302+ Bahrain -> "BH"
1303+ Burundi -> "BI"
1304+ Benin -> "BJ"
1305+ SaintBarthelemy -> "BL"
1306+ Bermuda -> "BM"
1307+ BruneiDarussalam -> "BN"
1308+ BoliviaPlurinationalStateOf -> "BO"
1309+ BonaireSintEustatiusAndSaba -> "BQ"
1310+ Brazil -> "BR"
1311+ Bahamas -> "BS"
1312+ Bhutan -> "BT"
1313+ BouvetIsland -> "BV"
1314+ Botswana -> "BW"
1315+ Belarus -> "BY"
1316+ Belize -> "BZ"
1317+ Canada -> "CA"
1318+ CocosKeelingIslands -> "CC"
1319+ CongoDemocraticRepublicOfThe -> "CD"
1320+ CentralAfricanRepublic -> "CF"
1321+ Congo -> "CG"
1322+ Switzerland -> "CH"
1323+ CoteDIvoire -> "CI"
1324+ CookIslands -> "CK"
1325+ Chile -> "CL"
1326+ Cameroon -> "CM"
1327+ China -> "CN"
1328+ Colombia -> "CO"
1329+ CostaRica -> "CR"
1330+ Cuba -> "CU"
1331+ CaboVerde -> "CV"
1332+ Curacao -> "CW"
1333+ ChristmasIsland -> "CX"
1334+ Cyprus -> "CY"
1335+ Czechia -> "CZ"
1336+ Germany -> "DE"
1337+ Djibouti -> "DJ"
1338+ Denmark -> "DK"
1339+ Dominica -> "DM"
1340+ DominicanRepublic -> "DO"
1341+ Algeria -> "DZ"
1342+ Ecuador -> "EC"
1343+ Estonia -> "EE"
1344+ Egypt -> "EG"
1345+ WesternSahara -> "EH"
1346+ Eritrea -> "ER"
1347+ Spain -> "ES"
1348+ Ethiopia -> "ET"
1349+ Finland -> "FI"
1350+ Fiji -> "FJ"
1351+ FalklandIslandsMalvinas -> "FK"
1352+ MicronesiaFederatedStatesOf -> "FM"
1353+ FaroeIslands -> "FO"
1354+ France -> "FR"
1355+ Gabon -> "GA"
1356+ UnitedKingdomOfGreatBritainAndNorthernIreland -> "GB"
1357+ Grenada -> "GD"
1358+ Georgia -> "GE"
1359+ FrenchGuiana -> "GF"
1360+ Guernsey -> "GG"
1361+ Ghana -> "GH"
1362+ Gibraltar -> "GI"
1363+ Greenland -> "GL"
1364+ Gambia -> "GM"
1365+ Guinea -> "GN"
1366+ Guadeloupe -> "GP"
1367+ EquatorialGuinea -> "GQ"
1368+ Greece -> "GR"
1369+ SouthGeorgiaAndTheSouthSandwichIslands -> "GS"
1370+ Guatemala -> "GT"
1371+ Guam -> "GU"
1372+ GuineaBissau -> "GW"
1373+ Guyana -> "GY"
1374+ HongKong -> "HK"
1375+ HeardIslandAndMcdonaldIslands -> "HM"
1376+ Honduras -> "HN"
1377+ Croatia -> "HR"
1378+ Haiti -> "HT"
1379+ Hungary -> "HU"
1380+ Indonesia -> "ID"
1381+ Ireland -> "IE"
1382+ Israel -> "IL"
1383+ IsleOfMan -> "IM"
1384+ India -> "IN"
1385+ BritishIndianOceanTerritory -> "IO"
1386+ Iraq -> "IQ"
1387+ IranIslamicRepublicOf -> "IR"
1388+ Iceland -> "IS"
1389+ Italy -> "IT"
1390+ Jersey -> "JE"
1391+ Jamaica -> "JM"
1392+ Jordan -> "JO"
1393+ Japan -> "JP"
1394+ Kenya -> "KE"
1395+ Kyrgyzstan -> "KG"
1396+ Cambodia -> "KH"
1397+ Kiribati -> "KI"
1398+ Comoros -> "KM"
1399+ SaintKittsAndNevis -> "KN"
1400+ KoreaDemocraticPeopleSRepublicOf -> "KP"
1401+ KoreaRepublicOf -> "KR"
1402+ Kuwait -> "KW"
1403+ CaymanIslands -> "KY"
1404+ Kazakhstan -> "KZ"
1405+ LaoPeopleSDemocraticRepublic -> "LA"
1406+ Lebanon -> "LB"
1407+ SaintLucia -> "LC"
1408+ Liechtenstein -> "LI"
1409+ SriLanka -> "LK"
1410+ Liberia -> "LR"
1411+ Lesotho -> "LS"
1412+ Lithuania -> "LT"
1413+ Luxembourg -> "LU"
1414+ Latvia -> "LV"
1415+ Libya -> "LY"
1416+ Morocco -> "MA"
1417+ Monaco -> "MC"
1418+ MoldovaRepublicOf -> "MD"
1419+ Montenegro -> "ME"
1420+ SaintMartinFrenchPart -> "MF"
1421+ Madagascar -> "MG"
1422+ MarshallIslands -> "MH"
1423+ NorthMacedonia -> "MK"
1424+ Mali -> "ML"
1425+ Myanmar -> "MM"
1426+ Mongolia -> "MN"
1427+ Macao -> "MO"
1428+ NorthernMarianaIslands -> "MP"
1429+ Martinique -> "MQ"
1430+ Mauritania -> "MR"
1431+ Montserrat -> "MS"
1432+ Malta -> "MT"
1433+ Mauritius -> "MU"
1434+ Maldives -> "MV"
1435+ Malawi -> "MW"
1436+ Mexico -> "MX"
1437+ Malaysia -> "MY"
1438+ Mozambique -> "MZ"
1439+ Namibia -> "NA"
1440+ NewCaledonia -> "NC"
1441+ Niger -> "NE"
1442+ NorfolkIsland -> "NF"
1443+ Nigeria -> "NG"
1444+ Nicaragua -> "NI"
1445+ NetherlandsKingdomOfThe -> "NL"
1446+ Norway -> "NO"
1447+ Nepal -> "NP"
1448+ Nauru -> "NR"
1449+ Niue -> "NU"
1450+ NewZealand -> "NZ"
1451+ Oman -> "OM"
1452+ Panama -> "PA"
1453+ Peru -> "PE"
1454+ FrenchPolynesia -> "PF"
1455+ PapuaNewGuinea -> "PG"
1456+ Philippines -> "PH"
1457+ Pakistan -> "PK"
1458+ Poland -> "PL"
1459+ SaintPierreAndMiquelon -> "PM"
1460+ Pitcairn -> "PN"
1461+ PuertoRico -> "PR"
1462+ PalestineStateOf -> "PS"
1463+ Portugal -> "PT"
1464+ Palau -> "PW"
1465+ Paraguay -> "PY"
1466+ Qatar -> "QA"
1467+ Reunion -> "RE"
1468+ Romania -> "RO"
1469+ Serbia -> "RS"
1470+ RussianFederation -> "RU"
1471+ Rwanda -> "RW"
1472+ SaudiArabia -> "SA"
1473+ SolomonIslands -> "SB"
1474+ Seychelles -> "SC"
1475+ Sudan -> "SD"
1476+ Sweden -> "SE"
1477+ Singapore -> "SG"
1478+ SaintHelenaAscensionAndTristanDaCunha -> "SH"
1479+ Slovenia -> "SI"
1480+ SvalbardAndJanMayen -> "SJ"
1481+ Slovakia -> "SK"
1482+ SierraLeone -> "SL"
1483+ SanMarino -> "SM"
1484+ Senegal -> "SN"
1485+ Somalia -> "SO"
1486+ Suriname -> "SR"
1487+ SouthSudan -> "SS"
1488+ SaoTomeAndPrincipe -> "ST"
1489+ ElSalvador -> "SV"
1490+ SintMaartenDutchPart -> "SX"
1491+ SyrianArabRepublic -> "SY"
1492+ Eswatini -> "SZ"
1493+ TurksAndCaicosIslands -> "TC"
1494+ Chad -> "TD"
1495+ FrenchSouthernTerritories -> "TF"
1496+ Togo -> "TG"
1497+ Thailand -> "TH"
1498+ Tajikistan -> "TJ"
1499+ Tokelau -> "TK"
1500+ TimorLeste -> "TL"
1501+ Turkmenistan -> "TM"
1502+ Tunisia -> "TN"
1503+ Tonga -> "TO"
1504+ Turkiye -> "TR"
1505+ TrinidadAndTobago -> "TT"
1506+ Tuvalu -> "TV"
1507+ TaiwanProvinceOfChina -> "TW"
1508+ TanzaniaUnitedRepublicOf -> "TZ"
1509+ Ukraine -> "UA"
1510+ Uganda -> "UG"
1511+ UnitedStatesMinorOutlyingIslands -> "UM"
1512+ UnitedStatesOfAmerica -> "US"
1513+ Uruguay -> "UY"
1514+ Uzbekistan -> "UZ"
1515+ HolySee -> "VA"
1516+ SaintVincentAndTheGrenadines -> "VC"
1517+ VenezuelaBolivarianRepublicOf -> "VE"
1518+ VirginIslandsBritish -> "VG"
1519+ VirginIslandsUS -> "VI"
1520+ VietNam -> "VN"
1521+ Vanuatu -> "VU"
1522+ WallisAndFutuna -> "WF"
1523+ Samoa -> "WS"
1524+ Yemen -> "YE"
1525+ Mayotte -> "YT"
1526+ SouthAfrica -> "ZA"
1527+ Zambia -> "ZM"
1528+ Zimbabwe -> "ZW"
1529+
1530+fromAlpha2 :: String -> Maybe Country
1531+fromAlpha2 = case _ of
1532+ "AD" -> Just Andorra
1533+ "AE" -> Just UnitedArabEmirates
1534+ "AF" -> Just Afghanistan
1535+ "AG" -> Just AntiguaAndBarbuda
1536+ "AI" -> Just Anguilla
1537+ "AL" -> Just Albania
1538+ "AM" -> Just Armenia
1539+ "AO" -> Just Angola
1540+ "AQ" -> Just Antarctica
1541+ "AR" -> Just Argentina
1542+ "AS" -> Just AmericanSamoa
1543+ "AT" -> Just Austria
1544+ "AU" -> Just Australia
1545+ "AW" -> Just Aruba
1546+ "AX" -> Just AlandIslands
1547+ "AZ" -> Just Azerbaijan
1548+ "BA" -> Just BosniaAndHerzegovina
1549+ "BB" -> Just Barbados
1550+ "BD" -> Just Bangladesh
1551+ "BE" -> Just Belgium
1552+ "BF" -> Just BurkinaFaso
1553+ "BG" -> Just Bulgaria
1554+ "BH" -> Just Bahrain
1555+ "BI" -> Just Burundi
1556+ "BJ" -> Just Benin
1557+ "BL" -> Just SaintBarthelemy
1558+ "BM" -> Just Bermuda
1559+ "BN" -> Just BruneiDarussalam
1560+ "BO" -> Just BoliviaPlurinationalStateOf
1561+ "BQ" -> Just BonaireSintEustatiusAndSaba
1562+ "BR" -> Just Brazil
1563+ "BS" -> Just Bahamas
1564+ "BT" -> Just Bhutan
1565+ "BV" -> Just BouvetIsland
1566+ "BW" -> Just Botswana
1567+ "BY" -> Just Belarus
1568+ "BZ" -> Just Belize
1569+ "CA" -> Just Canada
1570+ "CC" -> Just CocosKeelingIslands
1571+ "CD" -> Just CongoDemocraticRepublicOfThe
1572+ "CF" -> Just CentralAfricanRepublic
1573+ "CG" -> Just Congo
1574+ "CH" -> Just Switzerland
1575+ "CI" -> Just CoteDIvoire
1576+ "CK" -> Just CookIslands
1577+ "CL" -> Just Chile
1578+ "CM" -> Just Cameroon
1579+ "CN" -> Just China
1580+ "CO" -> Just Colombia
1581+ "CR" -> Just CostaRica
1582+ "CU" -> Just Cuba
1583+ "CV" -> Just CaboVerde
1584+ "CW" -> Just Curacao
1585+ "CX" -> Just ChristmasIsland
1586+ "CY" -> Just Cyprus
1587+ "CZ" -> Just Czechia
1588+ "DE" -> Just Germany
1589+ "DJ" -> Just Djibouti
1590+ "DK" -> Just Denmark
1591+ "DM" -> Just Dominica
1592+ "DO" -> Just DominicanRepublic
1593+ "DZ" -> Just Algeria
1594+ "EC" -> Just Ecuador
1595+ "EE" -> Just Estonia
1596+ "EG" -> Just Egypt
1597+ "EH" -> Just WesternSahara
1598+ "ER" -> Just Eritrea
1599+ "ES" -> Just Spain
1600+ "ET" -> Just Ethiopia
1601+ "FI" -> Just Finland
1602+ "FJ" -> Just Fiji
1603+ "FK" -> Just FalklandIslandsMalvinas
1604+ "FM" -> Just MicronesiaFederatedStatesOf
1605+ "FO" -> Just FaroeIslands
1606+ "FR" -> Just France
1607+ "GA" -> Just Gabon
1608+ "GB" -> Just UnitedKingdomOfGreatBritainAndNorthernIreland
1609+ "GD" -> Just Grenada
1610+ "GE" -> Just Georgia
1611+ "GF" -> Just FrenchGuiana
1612+ "GG" -> Just Guernsey
1613+ "GH" -> Just Ghana
1614+ "GI" -> Just Gibraltar
1615+ "GL" -> Just Greenland
1616+ "GM" -> Just Gambia
1617+ "GN" -> Just Guinea
1618+ "GP" -> Just Guadeloupe
1619+ "GQ" -> Just EquatorialGuinea
1620+ "GR" -> Just Greece
1621+ "GS" -> Just SouthGeorgiaAndTheSouthSandwichIslands
1622+ "GT" -> Just Guatemala
1623+ "GU" -> Just Guam
1624+ "GW" -> Just GuineaBissau
1625+ "GY" -> Just Guyana
1626+ "HK" -> Just HongKong
1627+ "HM" -> Just HeardIslandAndMcdonaldIslands
1628+ "HN" -> Just Honduras
1629+ "HR" -> Just Croatia
1630+ "HT" -> Just Haiti
1631+ "HU" -> Just Hungary
1632+ "ID" -> Just Indonesia
1633+ "IE" -> Just Ireland
1634+ "IL" -> Just Israel
1635+ "IM" -> Just IsleOfMan
1636+ "IN" -> Just India
1637+ "IO" -> Just BritishIndianOceanTerritory
1638+ "IQ" -> Just Iraq
1639+ "IR" -> Just IranIslamicRepublicOf
1640+ "IS" -> Just Iceland
1641+ "IT" -> Just Italy
1642+ "JE" -> Just Jersey
1643+ "JM" -> Just Jamaica
1644+ "JO" -> Just Jordan
1645+ "JP" -> Just Japan
1646+ "KE" -> Just Kenya
1647+ "KG" -> Just Kyrgyzstan
1648+ "KH" -> Just Cambodia
1649+ "KI" -> Just Kiribati
1650+ "KM" -> Just Comoros
1651+ "KN" -> Just SaintKittsAndNevis
1652+ "KP" -> Just KoreaDemocraticPeopleSRepublicOf
1653+ "KR" -> Just KoreaRepublicOf
1654+ "KW" -> Just Kuwait
1655+ "KY" -> Just CaymanIslands
1656+ "KZ" -> Just Kazakhstan
1657+ "LA" -> Just LaoPeopleSDemocraticRepublic
1658+ "LB" -> Just Lebanon
1659+ "LC" -> Just SaintLucia
1660+ "LI" -> Just Liechtenstein
1661+ "LK" -> Just SriLanka
1662+ "LR" -> Just Liberia
1663+ "LS" -> Just Lesotho
1664+ "LT" -> Just Lithuania
1665+ "LU" -> Just Luxembourg
1666+ "LV" -> Just Latvia
1667+ "LY" -> Just Libya
1668+ "MA" -> Just Morocco
1669+ "MC" -> Just Monaco
1670+ "MD" -> Just MoldovaRepublicOf
1671+ "ME" -> Just Montenegro
1672+ "MF" -> Just SaintMartinFrenchPart
1673+ "MG" -> Just Madagascar
1674+ "MH" -> Just MarshallIslands
1675+ "MK" -> Just NorthMacedonia
1676+ "ML" -> Just Mali
1677+ "MM" -> Just Myanmar
1678+ "MN" -> Just Mongolia
1679+ "MO" -> Just Macao
1680+ "MP" -> Just NorthernMarianaIslands
1681+ "MQ" -> Just Martinique
1682+ "MR" -> Just Mauritania
1683+ "MS" -> Just Montserrat
1684+ "MT" -> Just Malta
1685+ "MU" -> Just Mauritius
1686+ "MV" -> Just Maldives
1687+ "MW" -> Just Malawi
1688+ "MX" -> Just Mexico
1689+ "MY" -> Just Malaysia
1690+ "MZ" -> Just Mozambique
1691+ "NA" -> Just Namibia
1692+ "NC" -> Just NewCaledonia
1693+ "NE" -> Just Niger
1694+ "NF" -> Just NorfolkIsland
1695+ "NG" -> Just Nigeria
1696+ "NI" -> Just Nicaragua
1697+ "NL" -> Just NetherlandsKingdomOfThe
1698+ "NO" -> Just Norway
1699+ "NP" -> Just Nepal
1700+ "NR" -> Just Nauru
1701+ "NU" -> Just Niue
1702+ "NZ" -> Just NewZealand
1703+ "OM" -> Just Oman
1704+ "PA" -> Just Panama
1705+ "PE" -> Just Peru
1706+ "PF" -> Just FrenchPolynesia
1707+ "PG" -> Just PapuaNewGuinea
1708+ "PH" -> Just Philippines
1709+ "PK" -> Just Pakistan
1710+ "PL" -> Just Poland
1711+ "PM" -> Just SaintPierreAndMiquelon
1712+ "PN" -> Just Pitcairn
1713+ "PR" -> Just PuertoRico
1714+ "PS" -> Just PalestineStateOf
1715+ "PT" -> Just Portugal
1716+ "PW" -> Just Palau
1717+ "PY" -> Just Paraguay
1718+ "QA" -> Just Qatar
1719+ "RE" -> Just Reunion
1720+ "RO" -> Just Romania
1721+ "RS" -> Just Serbia
1722+ "RU" -> Just RussianFederation
1723+ "RW" -> Just Rwanda
1724+ "SA" -> Just SaudiArabia
1725+ "SB" -> Just SolomonIslands
1726+ "SC" -> Just Seychelles
1727+ "SD" -> Just Sudan
1728+ "SE" -> Just Sweden
1729+ "SG" -> Just Singapore
1730+ "SH" -> Just SaintHelenaAscensionAndTristanDaCunha
1731+ "SI" -> Just Slovenia
1732+ "SJ" -> Just SvalbardAndJanMayen
1733+ "SK" -> Just Slovakia
1734+ "SL" -> Just SierraLeone
1735+ "SM" -> Just SanMarino
1736+ "SN" -> Just Senegal
1737+ "SO" -> Just Somalia
1738+ "SR" -> Just Suriname
1739+ "SS" -> Just SouthSudan
1740+ "ST" -> Just SaoTomeAndPrincipe
1741+ "SV" -> Just ElSalvador
1742+ "SX" -> Just SintMaartenDutchPart
1743+ "SY" -> Just SyrianArabRepublic
1744+ "SZ" -> Just Eswatini
1745+ "TC" -> Just TurksAndCaicosIslands
1746+ "TD" -> Just Chad
1747+ "TF" -> Just FrenchSouthernTerritories
1748+ "TG" -> Just Togo
1749+ "TH" -> Just Thailand
1750+ "TJ" -> Just Tajikistan
1751+ "TK" -> Just Tokelau
1752+ "TL" -> Just TimorLeste
1753+ "TM" -> Just Turkmenistan
1754+ "TN" -> Just Tunisia
1755+ "TO" -> Just Tonga
1756+ "TR" -> Just Turkiye
1757+ "TT" -> Just TrinidadAndTobago
1758+ "TV" -> Just Tuvalu
1759+ "TW" -> Just TaiwanProvinceOfChina
1760+ "TZ" -> Just TanzaniaUnitedRepublicOf
1761+ "UA" -> Just Ukraine
1762+ "UG" -> Just Uganda
1763+ "UM" -> Just UnitedStatesMinorOutlyingIslands
1764+ "US" -> Just UnitedStatesOfAmerica
1765+ "UY" -> Just Uruguay
1766+ "UZ" -> Just Uzbekistan
1767+ "VA" -> Just HolySee
1768+ "VC" -> Just SaintVincentAndTheGrenadines
1769+ "VE" -> Just VenezuelaBolivarianRepublicOf
1770+ "VG" -> Just VirginIslandsBritish
1771+ "VI" -> Just VirginIslandsUS
1772+ "VN" -> Just VietNam
1773+ "VU" -> Just Vanuatu
1774+ "WF" -> Just WallisAndFutuna
1775+ "WS" -> Just Samoa
1776+ "YE" -> Just Yemen
1777+ "YT" -> Just Mayotte
1778+ "ZA" -> Just SouthAfrica
1779+ "ZM" -> Just Zambia
1780+ "ZW" -> Just Zimbabwe
1781+ _ -> Nothing
1782+
1783+allCountries :: Array Country
1784+allCountries = enumFromTo bottom top
1785+
1786+instance WriteForeign Country where
1787+ writeImpl = toAlpha2 >>> writeImpl
1788+
1789+instance ReadForeign Country where
1790+ readImpl f = do
1791+ let parse s = case fromAlpha2 s of
1792+ Just c -> pure c
1793+ Nothing -> throwError $ pure $ ForeignError $ "Unknown country: " <> s
1794+ s <- readImpl f
1795+ parse s
1796+