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
Whats the big deal with Scala
Search
todkar
July 11, 2012
Technology
220
1
Share
Whats the big deal with Scala
Scala is as expressive as Ruby and as performant as Java and let me show you how.
todkar
July 11, 2012
Other Decks in Technology
See All in Technology
Datadog 認定試験の概要と対策
uechishingo
0
230
JEP 522 Deep Dive - G1 GC同期コスト削減によるスループット向上を徹底検証&解説
tabatad
1
680
はじめてのDatadog
kairim0
0
260
OpenID Connectによるサービス間連携
takesection
0
150
ルールやカスタム機能、どう使う?理想の出力を引き出すために今知りたいIBM Bob 5つの機能
muehara
1
310
Spring AI × MCP 入門〜AIエージェントへのツール公開、境界設計から始める最小構成 〜
yuyamiyamoto
0
210
long-running-tasks
cipepser
3
460
最低限これだけ押さえれ大丈夫_Claude Enterprise/Team企業展開ガバナンス入門
tkikuchi
1
710
Chart.js が簡単に使えるようになっていたので OGP 画像生成に使った話
kamekyame
0
140
Databricks における 生成AIガバナンスの実践
taka_aki
1
270
エンジニアは生成AIと どのように向き合うべきか? ことばの意味という観点から
verypluming
3
340
TROCCOで始めるクラウドコストを民主化するためのFinOps
tk3fftk
3
560
Featured
See All Featured
Dominate Local Search Results - an insider guide to GBP, reviews, and Local SEO
greggifford
PRO
0
190
Stop Working from a Prison Cell
hatefulcrawdad
274
21k
Agile Leadership in an Agile Organization
kimpetersen
PRO
0
160
Lightning Talk: Beautiful Slides for Beginners
inesmontani
PRO
2
570
The untapped power of vector embeddings
frankvandijk
2
1.7k
Done Done
chrislema
186
16k
The Myth of the Modular Monolith - Day 2 Keynote - Rails World 2024
eileencodes
28
3.5k
Jamie Indigo - Trashchat’s Guide to Black Boxes: Technical SEO Tactics for LLMs
techseoconnect
PRO
0
160
Sam Torres - BigQuery for SEOs
techseoconnect
PRO
0
280
コードの90%をAIが書く世界で何が待っているのか / What awaits us in a world where 90% of the code is written by AI
rkaga
61
44k
Chrome DevTools: State of the Union 2024 - Debugging React & Beyond
addyosmani
10
1.2k
How to Create Impact in a Changing Tech Landscape [PerfNow 2023]
tammyeverts
55
3.4k
Transcript
What’s the big deal with Scala?
[email protected]
Introduc=on to Scala • Runs on JVM • Fuses object-‐oriented
& func=onal paradigms though biased towards func=onal style • Sta=cally-‐typed
As expressive as Ruby, As performant as Java
Why am I comparing with Ruby and Java?
Disclaimer • Professionally a Ruby and Java developer
• Haven’t worked with Scala on a “real” project • Based on my experience working with the Credit Union Findr
Why Expressiveness? • Not just preUy • Reduces boilerplate code
• Less code to deal with & maintain • Elegant solu=on
Ruby class defini=on
Scala class defini=on
Closures • Closures are blocks of code that can
be passed around as parameters • Closures “close over” variables outside of its scope
Closures in Ruby
Closures in Scala
Ruby monkey patching
Scala implicit conversions
Performance and Scalability constructs
Tail recursion • Special type of func=on recursion • Final
ac=on taken in a func=on is the recursive call • Can avoid penalty of crea=ng a new stack frame for each recursive call
Lets look at some code... Tail recursion
Parallel collec=ons • Just like regular collec=ons • Can
be operated upon by mul=ple cores • Use Divide-‐and-‐conquer algorithm • Write-‐your-‐own
Lets look at some code... Parallel collec=ons
Actors • Actors are high-‐level concurrency construct as opposed
to threads and shared memory model • Actors communicate via message passing • PaUern matching is used for message processing
Lets look at some code... Actors
Cri=cism • Slow compiler – sbt incremental compila=on
– Daemon compiler • Too many features
Other items of interest • REPL • TypeSafe (Scala, Akka,
Play!) • Heroku
Func=onal yet beau=ful Rug from Qom, Iran h/p://upload.wikimedia.org/wikipedia/commons/c/ca/Farsh_Qom.JPG)
Thank you! @todkar