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
The Functional Discipline
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
Pedro Costa
September 22, 2017
Programming
120
0
Share
The Functional Discipline
Slides of my talk at PartialConf 2017
Pedro Costa
September 22, 2017
More Decks by Pedro Costa
See All by Pedro Costa
Interruption Engineering - Part I
pfac
0
55
Spree
pfac
0
120
Workshop Git 2013
pfac
2
130
Other Decks in Programming
See All in Programming
安いハードウェアでVulkan
fadis
1
860
20260315 AWSなんもわからん🥲
chiilog
2
180
PHP 7.4でもOpenTelemetryゼロコード計装がしたい! / PHPerKaigi 2026
arthur1
1
450
Mastering Event Sourcing: Your Parents Holidayed in Yugoslavia
super_marek
0
130
Claude Codeログ基盤の構築
giginet
PRO
7
3.8k
Redox OS でのネームスペース管理と chroot の実現
isanethen
0
490
テレメトリーシグナルが導くパフォーマンス最適化 / Performance Optimization Driven by Telemetry Signals
seike460
PRO
2
200
Goの型安全性で実現する複数プロダクトの権限管理
ishikawa_pro
2
1.4k
ポーリング処理廃止によるイベント駆動アーキテクチャへの移行
seitarof
3
1.3k
「速くなった気がする」をデータで疑う
senleaf24
0
120
存在論的プログラミング: 時間と存在を記述する
koriym
5
730
Tamach-sre-3_ANDPAD-shimaison93
mane12yurks38
0
220
Featured
See All Featured
Avoiding the “Bad Training, Faster” Trap in the Age of AI
tmiket
0
110
Discover your Explorer Soul
emna__ayadi
2
1.1k
Templates, Plugins, & Blocks: Oh My! Creating the theme that thinks of everything
marktimemedia
31
2.7k
Visual Storytelling: How to be a Superhuman Communicator
reverentgeek
2
490
We Are The Robots
honzajavorek
0
210
The AI Search Optimization Roadmap by Aleyda Solis
aleyda
1
5.5k
Evolving SEO for Evolving Search Engines
ryanjones
0
170
The Impact of AI in SEO - AI Overviews June 2024 Edition
aleyda
5
780
Exploring anti-patterns in Rails
aemeredith
2
300
The Curious Case for Waylosing
cassininazir
0
280
It's Worth the Effort
3n
188
29k
The Language of Interfaces
destraynor
162
26k
Transcript
! " The Functional Discipline Pedro Costa @pfac @iampfac
None
Meet John
Meet John
Meet John
Meet John $ 100
None
An over-engineer
€ 1.0 for SOMEONE
New ideas
New ideas
New ideas
New ideas
New ideas
A functional way 1 2
1 class GenerateBillText 2 attr_accessor :currency, :value 3 4 def
initialize(currency:, value:) 5 @currency = currency 6 @value = value 7 end 8 9 def call 10 # ... generate image through ImageMagick ... 11 end 12 13 private 14 15 # ... any auxiliar method .. 16 end 17 18 GenerateBillText.new(currency: :eur, value: 1)
1 class StepChain 2 attr_accessor :klasses 3 4 def initialize(*klasses)
5 @klasses = klasses 6 end 7 8 def call(initial) 9 klasses.reduce(initial) do |current, klass| 10 klass.new(current).call 11 end 12 end 13 end 14 15 StepChain. 16 new(GenerateBillText, ...). 17 call(currency: :eur, value: 1)
1 class BillTextImage 2 attr_reader :path 3 4 def initialize(path:)
5 @path = path 6 end 7 end 8 9 BillTextImage.new(path: "~/tmp/bill_text.png")
None
None
None
None
None
None
None
?
None
None
?
None
None
OMG
None
None
HELP
– Cambridge Dictionary http://dictionary.cambridge.org/dictionary/english/discipline “the ability to control yourself (…),
even in difficult situations.”
– Cambridge Dictionary http://dictionary.cambridge.org/dictionary/english/discipline “the ability to control yourself (…),
even in difficult situations.”
Discipline is hard
Discipline is optional • You can reinvent the wheel, every
time • You can be inconsistent • You can break boundaries • You just should not.
Who’s disciplined?
None
–Daniel Kahneman, “Thinking, Fast and Slow” “System 1 operates automatically
and quickly, with little or no effort and no sense of voluntary control.”
–Daniel Kahneman, “Thinking, Fast and Slow” “System 2 allocates a!ention
to the effortful mental activities that demand it, (…). The operations (…) are often associated with (…) agency, choice and concentration.”
Habits?
None
–Admiral William H. McRaven “University of Texas at Austin 2014
Commencement Address” https://www.youtube.com/watch?v=pxBQLFLei70 “If you can’t do the little things right, you will never do the big things right.”
None
None
None
None
None
None
None
None
Explore
None
But take caution
None
None
Don’t go too far
In the end
All you need is Discipline
Thank you
! " The Functional Discipline Pedro “John” Costa @pfac @iampfac
Questions?