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
今日から使いたくなるifとfor
Search
イシカワ
November 23, 2019
Business
380
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
今日から使いたくなるifとfor
JJUG CCC 2019FallでLightning Talkしたスライドです。
コードに関してのご意見は受け付けます。
イシカワ
November 23, 2019
Other Decks in Business
See All in Business
株式会社スピークバディ 会社紹介資料
speakbuddy
1
230k
AIと働く実践 Agentがあなたの生産性を上げてくれない理由
ozakiomumkj
1
170
新卒採用向け説明資料
kazumakitao
PRO
1
4.1k
KGモーターズ会社紹介資料_2026.10
kgmotors
0
32k
AI時代、ホワイトワーカーは結局どうすれば良いのか?環境解説とOODA型キャリア戦略
makaibito
5
440
Sasuke Financial Lab 会社概要
sasukefinanciallab
0
740
Podpora KOVY | 24. 9. 2026
ggfs
PRO
0
440
アドバリスター株式会社 プロフェッショナルサービス事業
advalistar
0
18k
データ問い合わせエージェントと 求人推薦システムから見る、 当社のデータ活用事例
kazuyama88
0
250
データ基盤を Athena _ Glue から Databricks へ移行しました - 第4回 Youは何しにDatabricksへ!?
stanby_inc
0
250
メディフォン株式会社 会社説明資料
mediphone
0
730
I Ran 30+ GEO Experiments So You Don't Have To: What 200M AI Citations Say Actually Works
thomaspeham
1
150
Featured
See All Featured
The Mindset for Success: Future Career Progression
greggifford
PRO
0
540
Designing Dashboards & Data Visualisations in Web Apps
destraynor
232
55k
The Myth of the Modular Monolith - Day 2 Keynote - Rails World 2024
eileencodes
28
3.7k
Noah Learner - AI + Me: how we built a GSC Bulk Export data pipeline
techseoconnect
PRO
0
460
Producing Creativity
orderedlist
PRO
348
41k
Getting science done with accelerated Python computing platforms
jacobtomlinson
2
540
CoffeeScript is Beautiful & I Never Want to Write Plain JavaScript Again
sstephenson
162
16k
Building Better People: How to give real-time feedback that sticks.
wjessup
371
20k
Ecommerce SEO: The Keys for Success Now & Beyond - #SERPConf2024
aleyda
1
2.2k
It's Worth the Effort
3n
188
29k
Visual Storytelling: How to be a Superhuman Communicator
reverentgeek
2
710
Bash Introduction
62gerente
615
220k
Transcript
今日から使いたくなる ifとfor ウルシステムズ株式会社 石川将之
自己紹介 • 石川将之(イシカワ マサユキ) • ウルシステムズ株式会社2019卒入社 • プログラミング経験は半年 • 今の仕事はCRMシステム周り
• 性格はせっかち 2
研修でまなんだこと 3 資料作成 Tips プロジェク ト管理基礎 インタ ビュー モデリング ファシリ
テーション 見積り 業務フロー プログラミ ング クラウドイ ンフラ Webシステ ム構築
最も感動したこと 4 if & for サイコー 「分岐」と「繰り返し」さえあれば どんなことでもできる!
ifとforの万能性 • ソート 5 public static void main(String args[]) {
int[] array = { 8, 3, 3, 4, 5 }; for (int i = 0; i < array.length - 1; i++) { for (int j = array.length - 1; j > i; j--) { if (array[j] < array[j - 1]) { int tmp = array[j - 1]; array[j - 1] = array[j]; array[j] = tmp; } } } } → ifとforで出来る!
ifとforの万能性 • 業務ロジック 6 public static void main(String args[]) {
for(int i = 0; i < visiter.size(); i++){ if(visiter.getPass().isExistAAA){ user.add(visiter[i]); } if(visiter.isBBB){ break; } } for(int i = 0; i < user.size(); i++){ if(user.isLogin()){ if(user.isXXX){ doXXX(); } else if(user.isYYY) { doYYY(); } else if(user.isXXX){ doZZZ(); } } } } → ifとforで出来る!
ifとforの万能性 • Javaの中身もifとforで出来てる! 7 public static long parse(String s) {
・・・ for (k = wtb.length; --k >= 0;) if (wtb[k].regionMatches(true, 0, s, st, i - st)) { int action = ttb[k]; if (action != 0) { if (action == 1) { // pm if (hour > 12 || hour < 1) break syntax; else if (hour < 12) hour += 12; } else if (action == 14) { // am ・・・ } } } }
ifとforの万能性 • 女の子の落とし方 8 public static void main(String args[]) {
TalkResult result = talk(); if(result.getLINE()){ for(int i = 0; i < 365; i++){ sendMessage(); } } } → ifとforで出来る! if(tooManyMessage()){ break; }
ifとforの万能性 • 私の一日 9 public static void main(String args[]) {
sleep(); for(int i = sleepiness(); i == 0; i--){ if(sleepy()){ goToBed(); } else { goToWork(); } } } → ifとforで出来る!
ifとforの万能性 • 私の一日 10 public static void main(String args[]) {
sleep(); → ifとforで出来る! wakeUp(); goToWork(); for(int i = 0; i < task; i++){ doTask(); if(teiji()){ break; } } goBackHome(); }
最後に・・・ 11 if & for Love
最後に・・・ 12 if & for Love public static void main(String
args[]) { for(int i = 0; i < JJUG_CCC_LT.time; i++){ stayHere(); if(Audience.clapHand()){ break; } } }