---
title: みんなで Swift 復習会GO! in 札幌 – 10th′′
tags:  #カジュアルswift勉強会 #swift #イニシャライザー  
author: [熊谷友宏](https://docswell.com/user/es_kumagai)
site: [Docswell](https://www.docswell.com/)
thumbnail: https://bcdn.docswell.com/page/YE6YVQ95JV.jpg?width=480
description: 2019/12/25 に開催した「みんなで Swift 復習会GO! in 札幌」で使用した資料です。主にオープニング用の資料で、本編で使ったスライドは僅かで現場にいないと役に立たないかもしれませんが、何かの参考用に公開します。  実際の現場で使った本編資料は２ページですけれど、話が脱線する中で詳細に触れた項目が記載されていたページも数ページですけれど公開しておきました。  ※ Docswell での公開に移行する直前の Slideshare での閲覧数は 340 でした。
published: December 26, 19
canonical: https://docswell.com/s/es_kumagai/ZQRMEV-go-191225164535
---
# Page. 1

![Page Image](https://bcdn.docswell.com/page/YE6YVQ95JV.jpg)

ΈΜͳͰ
4XJGU ෮शձ
(0JOࡳຈ rUI⒌⒌
#minna_de_swift
ΧδϡΞϧ 4XJGU ϓϩάϥϛϯά


# Page. 2

![Page Image](https://bcdn.docswell.com/page/GE5GDRNGE4.jpg)


ࠓ೥͸‫׆‬ಈ‫ؒظࢭٳ‬த😘


# Page. 3

![Page Image](https://bcdn.docswell.com/page/972Y8D5D7R.jpg)

લճͷ෮शձ
(0JO෱Ԭr TU⒌


# Page. 4

![Page Image](https://bcdn.docswell.com/page/DJYG62KMJM.jpg)

લʑճͷ෮शձ͸ தࢭ
(0JOࡳຈr UI⒌


# Page. 5

![Page Image](https://bcdn.docswell.com/page/V7NGZ8R3E8.jpg)

‫۽‬୩༑޺
5PNPIJSP,VNBHBJ
⾣
4XJGU‫͕ޠݴ‬େ޷͖Ͱ͢ʂ
⾣
ΈΜͳͰָ͠Ήษ‫ڧ‬ձ͕େ޷͖Ͱ͢ʂ
⾣
ϓϩάϥϛϯάͷָ͠͞Λ఻͍͖͍͑ͯͨɻ
w ωοτϥδΦ
w ษ‫ڧ‬ձͷ஍ํ։࠵
w ಉਓࢽଈചձ


# Page. 6

![Page Image](https://bcdn.docswell.com/page/YJ9WZKMPJ3.jpg)

NPPLNPPLSBEJP NPPL
‫۽‬୩ͱ៸໘͕ϓϩάϥϛϯάίʔυͷ಺͔Β
ௌ͑ͯ͘͜Δ੠ʹࣖΛ܏ָ͚ͯ͠ΉϥδΦ
ຖि݄༵೔ ʹ഑৴
IUUQBVEJPCPPLKQ
⾣
ୈ࿩ 
ྲྀసͷٕज़ಉਓࢽଈചձͱษ‫ڧ‬ձ
⾣
ୈ࿩ 
ࡾ߲ԋࢉࢠ
⾣
ୈ࿩ 
5FDI-5ɺ੒ޭ΁ͷ  ͭͷλω
⾣
ୈ࿩ 
04ͷΞοϓσʔτରԠͷ෣୆ཪ
⾣
ୈ࿩ 
ٕज़ಉਓࢽɺϓϩάϥϛϯάͷ͋Δ೔ৗ
⾣
ୈ࿩ 
ͱ͖Ί͍ٕͨज़ॻ
⾣
ୈ࿩ 
ม਺
⾣
ୈ࿩ 
ϢʔβʔΛಋ͘ೝ஌৺ཧ


# Page. 7

![Page Image](https://bcdn.docswell.com/page/GJ8N1RLXED.jpg)

ΈΜͳͰ 4XJGU ෮शձ(0
ʜΈΜͳͰ4XJGU෮शձ(0JOࡳຈr  TU⒌
ʜΈΜͳͰ4XJGU෮शձ(0JOԭೄr  OE⒌ 4XJGU%BZ 
ʜΈΜͳͰ4XJGU෮शձ(0JOઋ୆r  SE⒌
ʜΈΜͳͰ4XJGU෮शձ(0JO෱Ԭr  UI⒌
4XJGU%BZ 
ʜΈΜͳͰ4XJGU෮शձ(0JO෱Ԭr  UI⒌
ʜΈΜͳͰ4XJGU෮शձ(0JO‫౎ژ‬r  UI⒌
ʜΈΜͳͰ4XJGU෮शձ(0JO௕໺r  UI⒌
XJUI/4&amp;(
ʜΈΜͳͰ4XJGU෮शձ(0JO෱Ԭr  UI⒌
ʜΈΜͳͰ4XJGU෮शձ(0JO‫ؠ‬खr  UI⒌
4XJGU%BZ 
ʜΈΜͳͰ4XJGU෮शձ(0JOࡳຈr UI⒌
NJOJ
ʜΈΜͳͰ4XJGU෮शձ(0JO෱Ԭr TU⒌
தࢭ


# Page. 8

![Page Image](https://bcdn.docswell.com/page/LJLPQKLNER.jpg)

ٕज़‫ܥ‬ಉਓࢽ
ࣗඅग़൛ͱಉਓࢽଈചձ
,JOEMF
#005)


# Page. 9

![Page Image](https://bcdn.docswell.com/page/47M412MQEW.jpg)

ۙ‫گ‬
Ҏ߱


# Page. 10

![Page Image](https://bcdn.docswell.com/page/P7RWLMVKE9.jpg)

͘͞ΒγϯσϨϥ
ҎདྷɺԠԉத
⾣
ΞΠυϧάϧʔϓʢਖ਼‫ن‬ϝϯόʔ  ໊ʣ
⾣
શ‫ۂ‬ΦϦδφϧ
⾣
౦‫Ͱ఺ڌ̎ژ‬೔‫׆‬ಈத
w ৽॓ΞΠυϧεςʔδ
w ळ༿‫ݪ‬ΞΠυϧεςʔδ
⾣
Ӧ‫ؒ࣌ۀ‬͸ɺҰൠʹ༦ํ͔Β·Ͱ
⾣
Իָੑॏࢹͷ‫׆‬ಈελΠϧ ʴ ΞΠυϧੑ
⾣
w ϥΠϒεςʔδ͕த৺
w ΧϑΣλΠϜ͋Γʢ࠙਌ձతͳ࣌ؒʣ
ϑΝϯ΁ͷ૝͍ͷਂ͞ͱ
‫ ͍ڧ‬౰ࣄऀҙ͕ࣝҹ৅త


# Page. 11

![Page Image](https://bcdn.docswell.com/page/PJXPWVZ5EX.jpg)

ΈΜͳͰ4XJGU෮शձ(0JO෱Ԭr TU⒌
!͘͞ΒΠϯλʔωοτ෱ԬΦϑΟε


# Page. 12

![Page Image](https://bcdn.docswell.com/page/3JKDVQ8R7D.jpg)

J04$PO
ʙ !$0%&amp;/0%&amp;JO-0/%0/


# Page. 13

![Page Image](https://bcdn.docswell.com/page/LE3RMP2G75.jpg)

ٕज़ॻయ̒
!஑ାαϯγϟΠϯγςΟ


# Page. 14

![Page Image](https://bcdn.docswell.com/page/8EDY6LZNEG.jpg)

ୈೋճٕज़ॻಉਓࢽതཡձ
!೔ຊ‫ڮ‬ϓϥβϚʔϜ


# Page. 15

![Page Image](https://bcdn.docswell.com/page/V7P6Y2DNJ8.jpg)

NPPLNPPLSBEJP
഑৴̑प೥‫ه‬೦ɾϓϥοτϑΥʔϜҠߦ
BVEJPCPPLKQ


# Page. 16

![Page Image](https://bcdn.docswell.com/page/2JV3GD1YEQ.jpg)

ΈΜͳͰ4XJGU෮शձ ͷ ෮शձ
!੨༿୆Ϩϯλϧεϖʔε


# Page. 17

![Page Image](https://bcdn.docswell.com/page/5EG38Y2W7L.jpg)

༧ఆ


# Page. 18

![Page Image](https://bcdn.docswell.com/page/4JQ59MPQ7P.jpg)

ίϛοΫϚʔέοτநબམͪ
 !౦‫ژ‬ϏοάαΠτ


# Page. 19

![Page Image](https://bcdn.docswell.com/page/K749XVYYE1.jpg)

ΈΜͳͰ4XJGU෮शձ(0JO෱Ԭr OE⒌
!-*/&amp;&#039;VLVPLB


# Page. 20

![Page Image](https://bcdn.docswell.com/page/LJ1KN36N7G.jpg)

ٕज़ॻయ೔໨
!஑ାαϯγϟΠϯγςΟ


# Page. 21

![Page Image](https://bcdn.docswell.com/page/GJWD4P4M72.jpg)

ίϛοΫϚʔέοτ౰མ଴ͪ
!౦‫ژ‬ϏοάαΠτ


# Page. 22

![Page Image](https://bcdn.docswell.com/page/4EZG2K2MJ3.jpg)

΋͘΋ࣥ͘චձ
ʙٕज़‫ܥ‬ಉਓࢽʗ঎‫ࢽۀ‬ɾൃදࢿྉɾϒϩάʙ
IUUQTUFDICPPLNFFUVQDPOOQBTTDPN
ࠓ‫ޙ‬ͷ։࠵༧ఆ
⾣ ٢೔ௐ੔த


# Page. 23

![Page Image](https://bcdn.docswell.com/page/Y76YVQV5EV.jpg)

΋͏͙͢೥
΅ͪ΅ͪ‫׆‬ಈ࠶։த😘


# Page. 24

![Page Image](https://bcdn.docswell.com/page/G75GDRDG74.jpg)

ΈΜͳͰ
4XJGU ෮शձ(0
#minna_de_swift


# Page. 25

![Page Image](https://bcdn.docswell.com/page/9J2Y8D8DJR.jpg)

‫ޕ‬લͷ෦
ΈΜͳͰ4XJGU෮शձ(0ͱ͸
⾣
ΈΜͳͰ4XJGU෮शձ
㾎 ͔ͤͬ͘ͳΒΈΜͳͱҰॹʹ෮श͍ͨ͠
ͦ͏ࢥͬͯ౦‫ژ‬ɾौ୩Ͱ࢝Ίͨษ‫ڧ‬ձ
⾣
ΈΜͳͰ4XJGU෮शձ(0͸ɺͦͷग़ு൛
㾎 ौ୩ͷ֎ʹ΋ษ‫ڧ‬ձͷָ͠͞Λ޿Ί͍ͨ
㾎 ༑ਓͷ఻खΛཔΓʹ೔ຊ֤஍Ͱ։࠵த
#minna_de_swift


# Page. 26

![Page Image](https://bcdn.docswell.com/page/DEYG626MEM.jpg)

ΈΜͳͰ 4XJGU ෮शձ(0
ʜΈΜͳͰ4XJGU෮शձ(0JOࡳຈr  TU⒌
ʜΈΜͳͰ4XJGU෮शձ(0JOԭೄr  OE⒌ 4XJGU%BZ 
ʜΈΜͳͰ4XJGU෮शձ(0JOઋ୆r  SE⒌
ʜΈΜͳͰ4XJGU෮शձ(0JO෱Ԭr  UI⒌
4XJGU%BZ 
ʜΈΜͳͰ4XJGU෮शձ(0JO෱Ԭr  UI⒌
ʜΈΜͳͰ4XJGU෮शձ(0JO‫౎ژ‬r  UI⒌
ʜΈΜͳͰ4XJGU෮शձ(0JO௕໺r  UI⒌
XJUI/4&amp;(
ʜΈΜͳͰ4XJGU෮शձ(0JO෱Ԭr  UI⒌
ʜΈΜͳͰ4XJGU෮शձ(0JO‫ؠ‬खr  UI⒌
4XJGU%BZ 
ʜΈΜͳͰ4XJGU෮शձ(0JOࡳຈr UI⒌
NJOJ
ʜΈΜͳͰ4XJGU෮शձ(0JO෱Ԭr TU⒌
࠶ձ


# Page. 27

![Page Image](https://bcdn.docswell.com/page/VJNGZ8Z378.jpg)

ΈΜͳͰ4XJGU෮शձ
ஊস‫ࣜܗ‬
⾣
ΈΜͳͱ4XJGUΛ෮श͍ͨ͠
⾣
͔ͤͬ͘ͳͷͰஊস͠ͳ͕Β
⾣
͍ͭͰ΋࿩͔͚ͯ͘͠Εͯ0,
#minna_de_swift


# Page. 28

![Page Image](https://bcdn.docswell.com/page/YE9WZKZPE3.jpg)

ΈΜͳͰ4XJGU෮शձ
৺͕͚
⾣
ΈΜͳ஌ͬͯΔɺ͸ࢥ͍ࠐΈ
⾣
ࣗ৴΍֬ূ͸ɺແͯ͘େৎ෉
⾣
ͳΜͱͳͦ͘͏ࢥ͏ɺେ‫ܴ׻‬
#minna_de_swift


# Page. 29

![Page Image](https://bcdn.docswell.com/page/GE8N1R1X7D.jpg)

ΈΜͳͰ4XJGU෮शձ
ָ͠Έํ
⾣
‫ͳʹؾ‬Δ࿩୊͕ग़͖ͯͨΒɺ࿩͢΋ ྑ͠ɻ
⾣
஌Βͳ͍ද‫͕ݱ‬ग़͖ͯͨΒɺ‫ײ‬ಈͨ͠Γ࿩୊ʹ͢Δ΋ ྑ͠ɻ
⾣
ͨͩɺฉ͍͍ͯΔ΋ ྑ͠ɻ
#minna_de_swift


# Page. 30

![Page Image](https://bcdn.docswell.com/page/LELPQKQN7R.jpg)

ΈΜͳͰ4XJGU෮शձ(0
-BOHVBHF(VJEF

ΈΜͳͰ4XJGU෮शձ
‫۽‬୩༑޺
IUUQF[OFUKQ
4XJGU


# Page. 31

![Page Image](https://bcdn.docswell.com/page/4JM4121Q7W.jpg)

ΠχγϟϥΠβʔ


# Page. 32

![Page Image](https://bcdn.docswell.com/page/PJRWLMLK79.jpg)

ΠχγϟϥΠβʔ
໾ׂ
⾣
Ϋϥεɺߏ଄ମɺྻ‫ܕڍ‬ͷΠϯελϯεΛੜ੒͢Δϓϩηε
㾎 ֤อଘ‫ܕ‬ϓϩύςΟʔʹॳ‫ظ‬஋Λઃఆ
㾎 Πϯελϯεੜ੒ʹඞཁͳɺॳ‫ظ‬ԽॲཧΛ࣮ࢪ


# Page. 33

![Page Image](https://bcdn.docswell.com/page/PEXPWVW57X.jpg)

ΠχγϟϥΠβʔ
ಛ௃

ಛఆͷ‫ܕ‬ΛΠϯελϯεԽ͢ΔͨΊͷಛघϝιου

4XJGUͷΠχγϟϥΠβʔ͸஋Λฦ͞ͳ͍

w
w
ׂΓ౰ͯΒΕͨྖҬ͕selfͰ౉͞ΕΔ
selfʹରͯ͠ॳ‫ظ‬ԽΛߦ͏
ΠϯελϯεΛ࣮֬ʹॳ‫ظ‬Խ͢Δ͜ͱ͕੹຿


# Page. 34

![Page Image](https://bcdn.docswell.com/page/3EKDVQVRJD.jpg)

ΠχγϟϥΠβʔ
ఆٛํ๏ͱ࢖༻ํ๏
⾣
initΩʔϫʔυͰఆٛ͢Δ
⾣
‫ʹ໊ܕ‬Ҿ਺ϦετΛఴ͑Δͱ࣮ߦ͞ΕΔ
class Object {
init() {
}
}
// インスタンスの生成
let object = Object()


# Page. 35

![Page Image](https://bcdn.docswell.com/page/L73RMPMGJ5.jpg)

ΠχγϟϥΠβʔ
ॳ‫ظ‬Խͷ‫ݪ‬ଇ
⾣
શͯͷϓϩύςΟʔͷॳ‫ظ‬Խ͕ඞཁ
⾣
ϓϩύςΟʔએ‫ͨ·࣌ݴ‬͸ΠχγϟϥΠβʔͷ࣮૷಺Ͱ࣮ࢪ
class Object {
var property1 = 0
var property2: Int
init(property2: Int) {
self.property2 = property2
}


# Page. 36

![Page Image](https://bcdn.docswell.com/page/87DY6L6N7G.jpg)

ΠχγϟϥΠβʔ
σΠχγϟϥΠβʔ
⾣
EFJOJUΩʔϫʔυͰఆٛ͢Δ
⾣
Ϋϥε͚ͩʹ࣮૷Ͱ͖ɺࢀর͞Εͳ͘ͳΔͱࣗಈ࣮ߦ
class Object {
deinit {
}


# Page. 37

![Page Image](https://bcdn.docswell.com/page/VJP6Y2YNE8.jpg)

&amp;OKPZ4XJGU
5IBOLZPV
ΈΜͳͰ4XJGU෮शձ(0
-BOHVBHF(VJEF

*OJUJBMJ[BUJPO
⾣
‫۽‬୩༑޺
IUUQF[OFUKQ
ΠχγϟϥΠβʔ


