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
Elixir Mini Introduction for Zürich Meetup
Search
Stefan Wintermeyer
February 20, 2017
Technology
0
200
Elixir Mini Introduction for Zürich Meetup
Stefan Wintermeyer
February 20, 2017
Tweet
Share
More Decks by Stefan Wintermeyer
See All by Stefan Wintermeyer
Disassembling Online Dating - FroSCon 2024
wintermeyer
0
50
Ash Framework - Elixir Kenya February 2024 Webinar
wintermeyer
1
97
The Greener Gras
wintermeyer
0
250
Rails vs. Phoenix vs. Hanami
wintermeyer
0
1.2k
RubyConfBy 2018 talk about WebPerformance with Rails 5.2
wintermeyer
3
300
WebPerformance für Reiseblogger
wintermeyer
0
210
WebPerformance with Rails 5.2
wintermeyer
5
940
FrOSCon 2017 talk about vutuv
wintermeyer
0
450
Lonestar ElixirConf 2017 talk about vutuv and Phoenix
wintermeyer
1
430
Other Decks in Technology
See All in Technology
白金鉱業Meetup Vol.17_あるデータサイエンティストのデータマネジメントとの向き合い方
brainpadpr
7
990
JavaにおけるNull非許容性
skrb
1
1.4k
Pwned Labsのすゝめ
ken5scal
0
250
EMConf JP 2025 懇親会LT / EMConf JP 2025 social gathering
sugamasao
2
170
CDKのコードを書く環境を作りました with Amazon Q
nobuhitomorioka
1
150
日経のデータベース事業とElasticsearch
hinatades
PRO
0
200
MIMEと文字コードの闇
hirachan
2
1.4k
エンジニアリング価値を黒字化する バリューベース戦略を用いた 技術戦略策定の道のり
kzkmaeda
6
1.5k
「正しく」失敗できる チームの作り方 〜リアルな事例から紐解く失敗を恐れない組織とは〜 / A team that can fail correctly
i35_267
2
710
【詳説】コンテンツ配信 システムの複数機能 基盤への拡張
hatena
0
190
NFV基盤のOpenStack更新 ~9世代バージョンアップへの挑戦~
vtj
0
330
AIエージェント時代のエンジニアになろう #jawsug #jawsdays2025 / 20250301 Agentic AI Engineering
yoshidashingo
3
190
Featured
See All Featured
Designing for humans not robots
tammielis
250
25k
Unsuck your backbone
ammeep
669
57k
I Don’t Have Time: Getting Over the Fear to Launch Your Podcast
jcasabona
32
2.1k
The Pragmatic Product Professional
lauravandoore
32
6.4k
CoffeeScript is Beautiful & I Never Want to Write Plain JavaScript Again
sstephenson
160
15k
Sharpening the Axe: The Primacy of Toolmaking
bcantrill
40
2k
RailsConf & Balkan Ruby 2019: The Past, Present, and Future of Rails at GitHub
eileencodes
133
33k
How to train your dragon (web standard)
notwaldorf
91
5.9k
Practical Tips for Bootstrapping Information Extraction Pipelines
honnibal
PRO
12
980
Speed Design
sergeychernyshev
27
800
How STYLIGHT went responsive
nonsquared
98
5.4k
10 Git Anti Patterns You Should be Aware of
lemiorhan
PRO
656
59k
Transcript
Elixir Stefan Wintermeyer @wintermeyer
Elixir is a functional, concurrent, general-purpose programming language that runs
on the Erlang virtual machine (BEAM). https://en.wikipedia.org/wiki/Elixir_(programming_language)
defmodule ModuleName do def hello do IO.puts "Hello World" end
end http://elixir-lang.org/crash-course.html
IEx Elixir’s interactive shell
None
Why would I want to learn Elixir? Why invest the
time and effort? I’m happy with Ruby and OO.
Three Main Reasons Spoiler Alert: Concurrency is not one of
them.
1. Speed Elixir runs circles around Ruby and Python.
2. Stability Speed is nothing without stability.
3. Hot-Code Upgrades Zero Downtime!
Some Code Examples
Assigning Values to Variables
iex(1)> a = 1 1 iex(2)>
iex(1)> a = 1 1 iex(2)> a = 2 2
iex(3)>
iex(1)> a = 1 1 iex(2)> a = 2 2
iex(3)> ^a = 3 ** (MatchError) no match of right hand side value: 3
Tuples
iex(1)> {a, b, c} = {10, 20, 30} {10, 20,
30} iex(2)>
iex(1)> {a, b, c} = {10, 20, 30} {10, 20,
30} iex(2)> a 10 iex(3)>
Pattern Matching
iex(1)> {a, b, c} = {10, 20, 30} {10, 20,
30} iex(2)>
iex(1)> {a, b, c} = {10, 20, 30} {10, 20,
30} iex(2)> {a, 20, c} = {10, 20, 30} {10, 20, 30} iex(3)>
iex(1)> {a, b, c} = {10, 20, 30} {10, 20,
30} iex(2)> {a, 20, c} = {10, 20, 30} {10, 20, 30} iex(3)> {a, 1, c} = {10, 20, 30} ** (MatchError) no match of right hand side value: {10, 20, 30}
If you want to get your feed wet with Elixir
I recommend two projects.
If you like hardware try http://nerves-project.org
None
If you like the web try www.phoenixframework.org
None
Phoenix Framework Productive. Reliable. Fast. Phoenix != Rails
None
mix phoenix.new blog Y cd blog vim config/dev.exs brew install
postgres brew services start postgres createuser -W --createdb blog demo mix ecto.create mix phoenix.gen.html Post posts subject body vim web/router.ex resources "/posts", PostController mix ecto.migrate mix phoenix.server Blog Example
Thank you! @wintermeyer