Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
プロを目指す人の為のRuby入門を学んでつまずいたところ
Search
yoshihiroUeki
June 27, 2020
1
610
プロを目指す人の為のRuby入門を学んでつまずいたところ
どう理解しようとしたか発表します
yoshihiroUeki
June 27, 2020
Tweet
Share
More Decks by yoshihiroUeki
See All by yoshihiroUeki
GitとGitHubの歴史と人間ドラマ
yoshihiroueki
1
910
Featured
See All Featured
Exploring the Power of Turbo Streams & Action Cable | RailsConf2023
kevinliebholz
28
4.3k
Visualizing Your Data: Incorporating Mongo into Loggly Infrastructure
mongodb
44
9.3k
Intergalactic Javascript Robots from Outer Space
tanoku
270
27k
Making the Leap to Tech Lead
cromwellryan
133
9k
Reflections from 52 weeks, 52 projects
jeffersonlam
347
20k
Fantastic passwords and where to find them - at NoRuKo
philnash
50
2.9k
Chrome DevTools: State of the Union 2024 - Debugging React & Beyond
addyosmani
2
160
Side Projects
sachag
452
42k
The Success of Rails: Ensuring Growth for the Next 100 Years
eileencodes
44
6.9k
A Modern Web Designer's Workflow
chriscoyier
693
190k
Templates, Plugins, & Blocks: Oh My! Creating the theme that thinks of everything
marktimemedia
28
2.1k
Git: the NoSQL Database
bkeepers
PRO
427
64k
Transcript
ϓϩΛࢦ͢ਓͷͨΊͷ Rubyೖ (νΣϦʔຊ) ΛֶΜͰͭ·͍ͣͨͱ͜Ζ
ࣗݾհ ২ ٛ५ twitter @yoshihiroUeki ϑΟϤϧυϒʔτΩϟϯϓͰ ֶΜͰ·͢
͡Ίʹ
νΣϦʔຊಡΜͰ͍ͯͭ·͍ͣͯຊͱ ʹΒΊͬ͜͢Δࣄ͕͋Γɺ ͜͏Ώ͏ֶͼํΛ͢Εྑ͔ͬͨͳʔͬͱ ࢥͬͨࣄΛൃද͍ͨ͠ͱ͓͍·͢
ൃදͷྲྀΕ ͡Ίʹ ൃදͷྲྀΕͷઆ໌ ͭ·͍ͣͨॴͷઆ໌ ͜͏Ώ͏ֶͼํΛ͢Εྑ͔ͬͨࣄ:ରࡦᶃʙᶉ ·ͱΊ ࠓ͜͜
త νΣϦʔຊΛ͜Ε͔ΒಡΉਓ ࠓಡΜͰΔਓ ͏Ұ෮श͠Α͏ͱ͍ͯ͠Δਓ ಉ͡ॴͰͭ·͍͍ͮͯΔ͔Εͳ͍ͷͰڞ༗ ͠Α͏ͱࢥ͍·ͨ͠
ҙ RubyΛҰ௨ΓֶΜͰ͍Δ͔ͨಘΒ ΕΔࣄগͳ͍͔Ͱ͢
ͭ·͍ͣͨॴ 7ষ 7.4.3 ྫɿɹվࡳػϓϩάϥϜ
ൃදͷεϥΠυʹ͋Δίʔυʹ͍ͭͯ ϓϩΛࢦ͢ਓͷͨΊͷRubyೖͷ7ষɺ 7.4.3ɹྫɿվࡳػϓϩάϥϜͷίʔυΛҾ༻͍ͯ͠·͢ɻ
γφϦΦʁ
ӡ͕Γ͍ͯΔ͔Ͳ͏͔Λผ͢Δ 150ԁͷූΛߪೖ͢Δ കాͰೖ͠ɺࡾࠃͰग़͢Δ ظ͢ΔޮՌ:ग़Ͱ͖ͳ͍
ͦͯࣸ͠ܦ͠·ͨ͠
ຊॻʹ͋Δ γʔέϯεਤΛݟΔ
ࣸܦͨ͠ίʔυͱ γʔέϯεਤ ΈͯΘ͔Βͳ͍
ςετίʔυͰ ΤϥʔͰΔ
Ͳ͏͠Α͏ʙ
͚͕࣌ؒͩա͗Δ
͜͏Ώ͏ֶͼ͔ͨ ͢Εྑ͔ͬͨࣄ
ରࡦᶃ
·ͣຊΛ ࠷ޙ·Ͱ ಡΈΔ
ࣸܦͨ͠ίʔυͷ ޡΓʹؾ͚ͮΔ
ҰΜͰ͍ΔՕॴΛ ΕͯΈΔࣄͰ ؾ͚Δࣄ͕͋Δ
ରࡦᶄ
ࣗͰγʔέϯεਤ Λ͔͍ͯΈΔ
None
গͣͭ͠Πϝʔδ͕ ௫ΜͰ͘Δ
ରࡦᶅ
ίϝϯτ͢Δ
Ҏલ
None
Մಡੑ͋͛ΔͨΊʹ ίϝϯτ߇͚͑ͯͨ Ͳ
ਓʹݟͤͣʹ͕ࣗ ཧղ͢ΔҝͩͬͨΒ ͍͍͔
·ͩश͍ͨͯͷਓ
None
ରࡦᶆ
ෳͷίʔυΛ දࣔͤ͞Δ
Ҏલ
̍ͭ̍ͭ ϑΝΠϧΛ ։͍ͯͨ
None
None
None
Πϝʔδ͕ͭ ͔Ίͳ͍
ෳͷϑΝΠ ϧΛදࣔ
None
ෳදࣔ͢ࣄͰ Ѳ͍͢͠ʂ
ରࡦᶇ
γʔέϯεਤͱ ίʔυΛࢦ͞͠ͳ͕Β ૾্ͷਓʹΛͩ͠ͳ͕ Βઆ໌͢Δ
ࢦΛ͞͠ͳ͕Βઆ໌͢ ΔաఔͰ಄ͷத͕ཧ ͞ΕΔ
Կ͕ཧղͰ͖ͯͳ͍͔ ໌֬ʹͳΔ
ରࡦᶈ
ίʔυΛݱ࣮ੈք ʹӨͤ͞Δ
ྫ͑ͪ͜Βͷ ίʔυ
None
umeda = Gate.new(:umeda) Ͱകా(umeda)ʹվࡳ͕Ͱ͖Δɻ ेࡾ(juso).newͰಉ͡Α͏ʹͰ͖ Δɻ Ticket.newͰ150ԁͷූΛߪೖ ͢Δɻ ͱ͍͏ྲྀΕͰݱ࣮ʹകా͔Βɺ ූΛങͬͯվࡳ௨ͯ͠ɺվࡳΛग़
ΔͱΠϝʔδͯ͠ΈΔɻ
खॻ͖Ͱॻ͍ͨ γʔέϯεਤ
None
ͱ
None
ίʔυΛݟൺͳ͕Β ૾ͯ͠ΈΔͱཧղ ͕ਐΉ
ରࡦऴΘΓ
ͦΕͰཧղᘳͰ ͢Ͷʁ
ͱݴΘΕΔͱࣗ৴ ͳ͍
͚ͲɺςΩετͱʹΒΊͬͯ͜͠ ͍ͨҎલͱൺΕཧղਐΜͩ ͱ͓͍·͢
·ͱΊ
৭ʑͳ͔֯Β ཧղ͢Δͷ େͩͱֶͼ·ͨ͠
ࣗҰਓͩͱ ৭ʑͳ͔֯Βཧղͷํ͢Δൃ ͜͜·Ͱੜ·Εͳ͔͔ͬͨͰ͢
ΞυόΠεΛ͘Εͨ ͕͍ؒͯ͘Εͯ ຊʹײँͰ͢
ऴΘΓ ͝ਗ਼ௌ͋Γ͕ͱ͏ ͍͟͝·ͨ͠