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
Little machines that eat strings
Search
Penelope Phippen
August 02, 2016
Technology
150
1
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Little machines that eat strings
A talk about regular expressions and computer science presented at SF dot RB
Penelope Phippen
August 02, 2016
More Decks by Penelope Phippen
See All by Penelope Phippen
Introducing Rubyfmt
penelope_zone
0
630
How RSpec Works
penelope_zone
0
6.9k
Quick and easy browser testing using RSpec and Rails 5.1
penelope_zone
1
120
Teaching RSpec to play nice with Rails
penelope_zone
2
190
What is processor (brighton ruby edition)
penelope_zone
0
150
What is processor?
penelope_zone
1
390
extremely defensive coding - rubyconf edition
penelope_zone
0
300
Agile, etc.
penelope_zone
2
270
Extremely Defensive Coding
penelope_zone
0
150
Other Decks in Technology
See All in Technology
"計画的無茶振り"を通してAIネイティブ世代の新人を育てる
subroh0508
1
130
生き様としてのSRE
hokkai7go
0
140
Devin プロモコードの受け取りと適用(2026.10.27)
kinopeee
1
760
AI Search (Foundry IQ) におけるRAGデータの準備と配置
ryomaru0825
1
100
Claude for Google Workspaces ポン出し/claude-for-google-workspace-slide-conversion
emiki
0
13k
Agent 活用環境の構築・運用のための AWS サービスのご紹介/agentcore-for-building-and-operating-agents
ren8k
1
280
Content Mapper APIの応用例~CSS Modules、言語ファイル~
uhyo
2
370
AIエージェント時代、Kaggleにどう取り組むか
takanao
2
430
Technical Project Manager の役割とやりがい、少しだけ AI
yoshiiryo1
0
430
渡米前の準備を制す!re:Invent 2026徹底準備術 / The Ultimate Preparation Guide for re:Invent 2026
yuj1osm
1
440
cdk deployとcdkd deploy、実際にデプロイして5倍速近くの差を実測した
yama3133
1
130
How we choose session proposals
kawaguti
PRO
1
190
Featured
See All Featured
Optimising Largest Contentful Paint
csswizardry
37
4k
Joys of Absence: A Defence of Solitary Play
codingconduct
1
560
Introduction to Domain-Driven Design and Collaborative software design
baasie
1
1.1k
Navigating Algorithm Shifts & AI Overviews - #SMXNext
aleyda
1
1.7k
CoffeeScript is Beautiful & I Never Want to Write Plain JavaScript Again
sstephenson
162
16k
Designing for humans not robots
tammielis
254
26k
Documentation Writing (for coders)
carmenintech
77
5.6k
Tell your own story through comics
letsgokoyo
1
1.1k
Navigating Weather and Climate Data
rabernat
0
570
Design of three-dimensional binary manipulators for pick-and-place task avoiding obstacles (IECON2024)
konakalab
0
640
StorybookのUI Testing Handbookを読んだ
zakiyama
31
7k
Unlocking the hidden potential of vector embeddings in international SEO
frankvandijk
0
1k
Transcript
Little machines that eat strings
I am @samphippen on all the internets
Computer Science
I ❤❤ Computer Science
But not the way it’s taught
None
CS (mostly) won’t make you better at Rails
CS (mostly) won’t make you better at Node
CS (mostly) won’t make you better at Browsers
But it’s super interesting
It’s like art for programmers
I’m gonna teach you a little computer science
None
Regular Expressions
In Ruby
>> /wtf/
>> /wtf/ === "abc"
>> /wtf/ === "abc" => false
>> /wtf/ === "wtf" => true
>> /wtf/ === "hiwtf" => true
>> /wtf/ === "hiwtflol" => true
So how does it regex?
Let’s introduce a model
Let’s say we don’t speak english
Let’s say we have a different alphabet
There are only two characters
Regular Expressions
>> / / === “ ” => true
>> / / === “ ” => false
>> / / === “ ” => false
>> / / === “ ” => true
>> / / === “ ” => true
>> / / === “ ” => true
This implies regular expressions have state
Let’s introduce a model
Regular Expressions
None
Machines have a starting state
/ /
/ /
Regexp.new(“”)
Regexp.new(“”)
/ /
Remember earlier when I said they have state?
/ /
None
None
Starting state Accepting state
This is called a “deterministic finite automata”
This model of Regex was extremely helpful to my learning
It’s a different way of thinking about regular expressions
To me, that’s what CS is
A series of techniques for thinking about computer differently
Thanks @samphippen
[email protected]