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
Haskell Introduction
Search
Seiya
July 14, 2018
Technology
120
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Haskell Introduction
プログラミング言語のHaskellの紹介スライドです。
JOI2017夏季セミナーで作った資料な気がします。
Seiya
July 14, 2018
More Decks by Seiya
See All by Seiya
ATProtocol ざっくり概要把握してみた @ DWeb Tokyo Meetup #2
silmin_
0
94
おうちGitLabのススメ
silmin_
5
2.1k
Git入門
silmin_
40
29k
暗号について
silmin_
0
220
LinuxCommand入門
silmin_
0
470
LinuxCommand入門2
silmin_
0
320
Webについて
silmin_
3
240
ネットワークとは
silmin_
0
300
コンピュータとは|初心者向け資料
silmin_
1
240
Other Decks in Technology
See All in Technology
「作れる」と「リリースできる」の間にあったもの── PdMを外して見えた、PdMがやるべき仕事/Buildable ≠ Shippable: What Removing the PM Taught Me About the PM’s Job
yappli_developers
0
390
なぜAI時代に技術記事を書くのか?どう書くのか? 〜bunの場合〜
kworkdev
PRO
0
1.2k
Adversary Infrastructure Hunting101
disconinja
0
180
AIエージェントに 権限と鍵をどこまで渡すか
nrinetcom
PRO
2
160
ひとりで始めた AI駆動開発、チームに広げて何が変わったのか
kenichiodo
1
170
AI時代のエンジニアの情報発信〜個人の発信を組織の力に変える〜
ryo_kawamata
0
5.6k
[FECONF-2026] 신대륙을 향한 카카오페이증권 프론트엔드 항해기 (이주승)
l1ghthouse
0
330
ALBのLCU予約とトラフィックの波によるプロダクト理解 / Understanding ALB LCU and Traffic Spikes
mito201
0
110
AI秘書と毎日働くのはもう当たり前。開発以外の業務に足りない機能をどう埋める?
minorun365
PRO
4
2k
AI AgentによるEmbedded SREの取り組み
tgidgd
1
290
20261031_IoTLT_vol140_kitazaki_v1.pdf
kitazaki
0
120
AI Search (Foundry IQ) におけるRAGデータの準備と配置
ryomaru0825
1
100
Featured
See All Featured
How Fast Is Fast Enough? [PerfNow 2025]
tammyeverts
3
960
Optimising Largest Contentful Paint
csswizardry
37
4k
JAMstack: Web Apps at Ludicrous Speed - All Things Open 2022
reverentgeek
1
660
The B2B funnel & how to create a winning content strategy
katarinadahlin
PRO
1
590
SEO for Brand Visibility & Recognition
aleyda
0
4.8k
"I'm Feeling Lucky" - Building Great Search Experiences for Today's Users (#IAC19)
danielanewman
230
23k
How to Talk to Developers About Accessibility
jct
2
600
Efficient Content Optimization with Google Search Console & Apps Script
katarinadahlin
PRO
1
950
JavaScript: Past, Present, and Future - NDC Porto 2020
reverentgeek
52
6.2k
The Straight Up "How To Draw Better" Workshop
denniskardys
239
140k
Tips & Tricks on How to Get Your First Job In Tech
honzajavorek
1
820
Designing for Timeless Needs
cassininazir
1
540
Transcript
Haskell Introduction mina @silmin_
はじめに 「純粋関数型データ構造」という本で純粋関数型(ryを学んだ () これは ➢ 参照透過性 ➢ 永続性 ➢ 副作用のNASA
➢ なんでも関数 ➢ 簡潔かつ混沌() などが特徴(らしい) 今回はHaskellで実装した
Haskell とは 芸術
型宣言 Haskellは美しい data Color = Red | Blue | Yellow
toJpn :: Color -> String toJpn Red = “aka” toJpn Blue = “ao” toJpn Yellow = “ki” main = print $ toJpn Red パターンマッチ 関数実行 & 出力 enum Color { Red, Blue, Yellow };
関数のいろいろ 関数名 引数1 引数2.......で呼び出し temp a b -> a `temp` b とも書ける (
1 + ) , ( 5 * ) : 一引数関数 ( 1 + ) . ( 5 * ) : 関数合成 ( 5倍して1足す関数) f x y = print $ gcd x y f x = print . gcd x f = (print .) . gcd
実行してみる 関数合成
二分探索木(木の定義) data Tree a = Leaf | Node (Tree a)
a (Tree a) Leaf - 末端ノードの先にいる 実質虚無 末 Node - ただのノード 子を持ってる a ... ... 葉 葉
二分探索木(search関数) search::Ord a => Tree a -> a -> Bool
search Leaf b = False search (Node tl a tr) b = if b < a then search tl b else if b > a then search tr b else True 型宣言 パターンマッチ
最後に 興味を持った方は「Haskell Platform」で検索 ※UNIX / Mac の方はパッケージがあるのでinstallしましょう Haskellには光と闇が存在します
Haskell とは 芸術
Thank you for listening !!!