回答編集履歴
2
わける。
answer
CHANGED
@@ -3,4 +3,18 @@
|
|
3
3
|
//=> ワシントン
|
4
4
|
```
|
5
5
|
|
6
|
-
でいいでしょうか?
|
6
|
+
でいいでしょうか?
|
7
|
+
|
8
|
+
【追記】
|
9
|
+
|
10
|
+
一つ一つ分けて書くとこうなります。
|
11
|
+
|
12
|
+
```swift
|
13
|
+
let country = countryArr[2] //egypt
|
14
|
+
print(country)
|
15
|
+
//=> (100, "カイロ", "Africa")
|
16
|
+
|
17
|
+
let location = country.location
|
18
|
+
print(location)
|
19
|
+
//=> Africa
|
20
|
+
```
|
1
output
answer
CHANGED
@@ -1,5 +1,6 @@
|
|
1
1
|
```swift
|
2
2
|
print(countryArr[0].capital)
|
3
|
+
//=> ワシントン
|
3
4
|
```
|
4
5
|
|
5
6
|
でいいでしょうか?
|