Skip to content

Instantly share code, notes, and snippets.

@ralfebert
Last active February 24, 2022 01:06
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ralfebert/98be5592cff97304505ca939c0de9cbb to your computer and use it in GitHub Desktop.
Save ralfebert/98be5592cff97304505ca939c0de9cbb to your computer and use it in GitHub Desktop.
func countriesExampleData() -> [Country] {
[
Country(
id: "at",
name: "Austria",
capital: "Vienna",
population: 8_935_112,
drivingSide: .right
),
Country(
id: "be",
name: "Belgium",
capital: "Brussels",
population: 11_492_641,
drivingSide: .right,
historyFact: "In Belgium, there was no elected government for 589 days in 2010."
),
Country(
id: "de",
name: "Germany",
capital: "Berlin",
population: 83_190_556,
drivingSide: .right,
historyFact: "Germany was separated in two separate countries until 1989."
),
Country(
id: "gr",
name: "Greece",
capital: "Athens",
population: 10_718_565,
drivingSide: .right
),
Country(
id: "fr",
name: "France",
capital: "Paris",
population: 67_413_000,
drivingSide: .right
),
Country(
id: "gb",
name: "United Kingdom",
capital: "London",
population: 67_081_000,
drivingSide: .left,
currency: Currency(name: "£", exchangeRateToEuro: 1.17)
),
Country(
id: "ch",
name: "Switzerland",
capital: "Bern",
population: 8_570_146,
drivingSide: .right,
currency: Currency(name: "CHF", exchangeRateToEuro: 0.94)
),
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment