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
Safe Navigation in Ruby 2.3
Search
Rick Liu
January 22, 2016
Programming
0
62
Safe Navigation in Ruby 2.3
Introduction the new operator and its problem.
Rick Liu
January 22, 2016
Tweet
Share
More Decks by Rick Liu
See All by Rick Liu
Functional Programming Concepts
rickliu
0
220
You Don't Need a JavaScript Framework
rickliu
0
130
Agile Design
rickliu
0
78
Active Job in Rails 4.2
rickliu
0
57
Other Decks in Programming
See All in Programming
「ブロックテーマでは再現できない」は本当か?
inc2734
0
960
20260127_試行錯誤の結晶を1冊に。著者が解説 先輩データサイエンティストからの指南書 / author's_commentary_ds_instructions_guide
nash_efp
1
950
360° Signals in Angular: Signal Forms with SignalStore & Resources @ngLondon 01/2026
manfredsteyer
PRO
0
120
Oxlintはいいぞ
yug1224
5
1.3k
例外処理とどう使い分ける?Result型を使ったエラー設計 #burikaigi
kajitack
16
6k
Patterns of Patterns
denyspoltorak
0
1.4k
AIフル活用時代だからこそ学んでおきたい働き方の心得
shinoyu
0
130
AI Agent の開発と運用を支える Durable Execution #AgentsInProd
izumin5210
7
2.3k
プロダクトオーナーから見たSOC2 _SOC2ゆるミートアップ#2
kekekenta
0
210
AIによるイベントストーミング図からのコード生成 / AI-powered code generation from Event Storming diagrams
nrslib
2
1.9k
CSC307 Lecture 01
javiergs
PRO
0
690
AI Schema Enrichment for your Oracle AI Database
thatjeffsmith
0
270
Featured
See All Featured
Everyday Curiosity
cassininazir
0
130
Designing for humans not robots
tammielis
254
26k
Sharpening the Axe: The Primacy of Toolmaking
bcantrill
46
2.7k
The Illustrated Children's Guide to Kubernetes
chrisshort
51
51k
Building Better People: How to give real-time feedback that sticks.
wjessup
370
20k
BBQ
matthewcrist
89
10k
A Guide to Academic Writing Using Generative AI - A Workshop
ks91
PRO
0
200
Balancing Empowerment & Direction
lara
5
880
JavaScript: Past, Present, and Future - NDC Porto 2020
reverentgeek
52
5.8k
"I'm Feeling Lucky" - Building Great Search Experiences for Today's Users (#IAC19)
danielanewman
231
22k
Leading Effective Engineering Teams in the AI Era
addyosmani
9
1.6k
Design in an AI World
tapps
0
140
Transcript
Safe Navigation in Ruby 2.3
Safe Navigation > some_array.first.positive? > [].first.positive? (value = some_array.first) &&
value.positive? > some_array.first&.positive? # => true # => NoMethodError: undefined method `positive?' for nil:NilClass # => nil
Safe Navigation if user.account && user.account.trial? # process trial account
settings end if user.account&.trial? # process trial account settings end if user.account && user.account != previous_account # setup new account end if user.account &.!= previous_account # setup new account end &.&, &.<<, and &.+