Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
Monads na prática - QConSP 2014
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
Breno Ferreira
April 09, 2014
Programming
140
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Monads na prática - QConSP 2014
Breno Ferreira
April 09, 2014
More Decks by Breno Ferreira
See All by Breno Ferreira
TDC Globo Sistemas Distribuídos
brenoferreira
1
110
Trabalho Remoto TDC Globo 2020
brenoferreira
1
130
Immutable Da
brenoferreira
0
100
Remote Work
brenoferreira
0
110
Fun with Types
brenoferreira
0
250
RxJava
brenoferreira
1
420
.NET Além do Mundo Microsoft
brenoferreira
0
110
TDC2013 - Programação assíncrona com Javascript
brenoferreira
1
590
TDD com Javascript
brenoferreira
1
540
Other Decks in Programming
See All in Programming
手動確認はもう限界 〜XCUITestでCustom URL Schemeの遷移を起動種別ごとに自動テストする〜 / Testing Custom URL Schemes with XCUITest
otouto
0
280
JPUG勉強会 OSSデータベースの内部構造を理解しよう(第2回)
oga5
0
220
WebMCP Challenge に星空観察アプリで参加した話
okajun35
0
170
Webの地図
yosuke_furukawa
PRO
6
4.5k
MVNOの申込からeSIM開通までをiOSアプリでつなぐ- 本人確認・MNP・通信事業者基盤をまたぐ実装
satotakeshi
0
410
自分的「カンファレンスの楽しみ方」
syumai
0
200
AgentCore CLI で進化した AWS での AI エージェントの作り方 : 必要な機能を必要な時に
icoxfog417
PRO
3
340
世界の中心で、AI(App Intents)をさけぶ ー App Intents中心設計の実践ガイド
touyou
0
570
マイコン向けの軽量Ruby「PicoRuby」で各種デバイスを制御するネイティブアプリの実現手法
bash0c7
0
390
AIを上手に使っていこうとしたら越境せざるを得なくなった話 〜実践1年で見えた境界を越えなければならない理由と進め方〜 / Crossing borders with AI
tomoyakitaura
4
1.2k
[DroidKaigi 2026] Bring your own phones to Gradle Managed Devices
f2lk
0
120
標準パッケージに uuid が追加された 背景から見る Go らしい意思決定 / go_127_uuid_decision
convto
5
7.1k
Featured
See All Featured
GitHub's CSS Performance
jonrohan
1033
470k
Thoughts on Productivity
jonyablonski
76
5.4k
How to Create Impact in a Changing Tech Landscape [PerfNow 2023]
tammyeverts
56
3.5k
We Have a Design System, Now What?
morganepeng
55
8.3k
Save Time (by Creating Custom Rails Generators)
garrettdimon
PRO
32
4.8k
The Invisible Side of Design
smashingmag
301
52k
Responsive Adventures: Dirty Tricks From The Dark Corners of Front-End
smashingmag
254
22k
No one is an island. Learnings from fostering a developers community.
thoeni
21
3.8k
Navigating the Design Leadership Dip - Product Design Week Design Leaders+ Conference 2024
apolaine
2
430
Cheating the UX When There Is Nothing More to Optimize - PixelPioneers
stephaniewalter
287
14k
Java REST API Framework Comparison - PWX 2021
mraible
34
9.7k
A Guide to Academic Writing Using Generative AI - A Workshop
ks91
PRO
1
460
Transcript
MONADS NA PRÁTICA @breno_ferreira Breno Ferreira
PROGRAMAÇÃO FUNCIONAL É ASSUSTADOR Functors Monoids Catamorphism MONAD
PROGRAMAÇÃO FUNCIONAL É POUCO FAMILIAR Functors Monoids Catamorphism MONAD
PROGRAMAÇÃO FUNCIONAL É POUCO FAMILIAR Mappables Monoids Catamorphism MONAD
PROGRAMAÇÃO FUNCIONAL É POUCO FAMILIAR Mappables Monoids Aggregatables MONAD
PROGRAMAÇÃO FUNCIONAL É POUCO FAMILIAR Mappables Composables Aggregatables MONAD
PROGRAMAÇÃO FUNCIONAL É POUCO FAMILIAR Mappables Composables Aggregatables Chainable
ORIENTAÇÃO A OBJETO É ASSUSTADOR! Polimorfismo Herança Variancia interfaces SOLID
SRP, OCP, LSP, ISP, DIP IoC, DI, MVC, ORM, GoF, PoEAA…
ORIENTAÇÃO A OBJETO É ASSUSTADOR! Polimorfismo Herança Variancia interfaces SOLID
SRP, OCP, LSP, ISP, DIP IoC, DI, MVC, ORM, GoF, PoEAA…
MAS O QUE É UMA MONAD?
MAS O QUE É UMA MONAD? A monad is just
a monoid in the category of endofunctors. James Iry http://james-iry.blogspot.com.br/2009/05/brief-incomplete-and-mostly-wrong.html
DEFINIÇÃO DE UMA MONAD type Monad return :: a ->
m a (>>=) :: m a -> (a -> m b) -> m b
TRADUÇÃO interface Monad<A> static Create(value: A): Monad<A> flatMap(mapper: A ->
Monad<B>): Monad<B>
MAS PARA QUE AS MONADS SÃO ÚTEIS? • Nulls •
Exceptions • Assincronia • Reactive Programming • Mutable state • etc…
HTTPS://GITHUB.COM/BRENOFERREIRA/CSHARP.FUN
OBRIGADO! @breno_ferreira