SlideShare a Scribd company logo
1 of 14
今回の問題セットのコンセプト
• 基本的に「考察をすると実装が楽になる」のような考
察重視な問題を集めました
• たまに「考察をしないとどうしようもない」みたいな問題も
• 前半のコード祭り予選過去問については、基本的に
「知っておいたほうがいい問題」を集めました
• 8月31日、とかは典型だけど知らないと難しそう
• (あとは、なるべく古い問題でかつ配点が100点のもの、
という縛りで選んでいます)
• 以下は各問題のドチャクソ適当な解説です
• 自分で通していない問題も多いので、間違っていたり
もっと大事なとこ、大変なとこがあるが??? みたい
なのはバシバシ指摘してください
A : ダブル文字列
• ちゃんとやっても良いが、与えられた入力を2回出力す
るだけで良い
• FA : lrmystp (35s)
B : とても長い数列
• ついつい順番(何番目にどの数字が来るか)を知りた
くなるが、和を求めるだけならどの数字が何回登場す
るか、だけ分かれば良い
• A_i は 2^(n - i) 回登場する
• FA : lrmystp (2m43s)
C : 8月31日
• どれを手伝ってもらうのが良いか、というのは「手
伝ってもらったことにより得をする時間」に依存する
• つまり、(A_i – B_i) が大きい順に選ぶのが最適
• (A_i – B_i) でソートしてほい
• 類題 : この前の夏合宿の1日目のK パンプキン
(http://jag2017summer-day1.contest.atcoder.jp/tasks/jag2017summer_day1_k)
• FA : lrmystp (7m45s)
D : 錬金術士
• 文字列長が 10^5 で一見やばい
• 実は、(S1 から最低限使わなきゃいけない文字数)が
N以下でかつ(S1 から最大限使える文字数)が N以上
なら錬金可能
• 証明はそこまで難しくない(はず)
• あとはちゃんと上の文字数を調べられるか
• 各文字が S1, S2 にいくつずつあるかを見れば良い
• FA : lrmystp (22m33s)
E : 壊れた電車 (1/2)
• 最短何分で終わるか知りたいので、二分探索したい気
分になる
• T 分しか時間がない場合、左にいる作業員から順番に
「整備していない車両のうち一番左のものまで行き
戻って来る」または「最初右に行き、あるところで
戻ってきて整備していない車両のうち一番左のものま
で行く」ということをやらせるのが最適で、それで全
ての車両を網羅できているかを見れば良い
E : 壊れた電車 (2/2)
• すぐに二分探索が見える問題はもちろん、ぱっと見は
二分探索に見えない問題を二分探索に落とし込んで解
けるようになると良い
• もちろんすぐに二分探索に見えるようになるのがベストだが
• 類題(?): https://yukicoder.me/problems/no/448
https://yukicoder.me/problems/no/461
• FA : lrmystp (46m01s)
F : 登山家
• stack で頑張る(こういうの苦手だから嫌い)
• 類問(?): カーペット
(http://kupc2013.contest.atcoder.jp/tasks/kupc2013_d)
• これもstackで頑張る問題
• これを用いると最大長方形が求まる
(http://arc081.contest.atcoder.jp/tasks/arc081_d)
• FA : ferin (51m07s)
• stack で頑張る(こういうの苦手だから嫌い)
• 類問(?): カーペット
(http://kupc2013.contest.atcoder.jp/tasks/kupc2013_d)
• これもstackで頑張る問題
• これを用いると最大長方形が求まる
(http://arc081.contest.atcoder.jp/tasks/arc081_d)
• FA : ferin (51m07s)
G : 直径
• 2個のグラフの端っこと重心(?) を求める
• O(N^2) が間に合うのできつくない
• 端と端をつなぐ場合が最長、重心と重心をつなぐ場合
が最短
• 最短の場合、元のグラフの直径の方が大きくてそちらを出力
しなければならない場合があることに注意
• FA : kobae964 (14m32s)
H : FA
• 結論から言うと、自分がFA を取る問題については、他
の人が解く時間 (B_i) が早い順に解いていくのが最適に
なる
• その状態から適当に swap してみるとそういう気持ちになる
• なので、B_i でソートしてから
• dp[今見てる問題][今までの FA の数] := かかった時間のmin
• という DP をすると解ける
• FA : kobae964(23m07s)
I : Be Together
• 結論から言うと、(x, y) (x >= 0, y >= 0) にいる人がTター
ン後に原点にいられる条件は、
• T * (T + 1) / 2 – (x + y) = (偶数)
• となる
• 証明は少しむずそう
• まずは全ての点の原点からのマンハッタン距離の偶奇が一致して
いるかどうかを調べて、あとは一番遠いところとの距離を超えて
かつ偶奇が一致するところを見つける
• FA : kobae964 (33m24s)
J : お釣りの嫌いな高橋君
• こういう問題嫌い(直球)
• がっつり桁DP は出なくても、こういう問題なら十分出
る可能性がありそう
• 昨日ちょっと書いた感じだと、一つ前の硬貨が10枚以上あったとき、そ
れをギリギリまで使う場合と一つ残しておく場合を両方見なきゃいけな
くてクソめんどくさそうだった
• いくつ繰り上がったかを持ってdpすればいいらしい、なるほど
• 類題(?): https://yukicoder.me/problems/no/319
• FA : kobae964 (42m56s)
K : 蟻本
• 1個の三角形を作るなら、用いるのは連続する3つの数
に限られる → 2個の場合は?
• 連続する3つの数 が2箇所 か、範囲が交差している場合
がある
• 1, 1, 2, 2, 5, 5 みたいな
• 範囲が交差している場合も、連続する6つの数に限られ
る
• FA : rickytheta (1h11m59s)

More Related Content

Recently uploaded

論文紹介:Content-Aware Token Sharing for Efficient Semantic Segmentation With Vis...
論文紹介:Content-Aware Token Sharing for Efficient Semantic Segmentation With Vis...論文紹介:Content-Aware Token Sharing for Efficient Semantic Segmentation With Vis...
論文紹介:Content-Aware Token Sharing for Efficient Semantic Segmentation With Vis...Toru Tamaki
 
TSAL operation mechanism and circuit diagram.pdf
TSAL operation mechanism and circuit diagram.pdfTSAL operation mechanism and circuit diagram.pdf
TSAL operation mechanism and circuit diagram.pdftaisei2219
 
Postman LT Fukuoka_Quick Prototype_By Daniel
Postman LT Fukuoka_Quick Prototype_By DanielPostman LT Fukuoka_Quick Prototype_By Daniel
Postman LT Fukuoka_Quick Prototype_By Danieldanielhu54
 
Open Source UN-Conference 2024 Kawagoe - 独自OS「DaisyOS GB」の紹介
Open Source UN-Conference 2024 Kawagoe - 独自OS「DaisyOS GB」の紹介Open Source UN-Conference 2024 Kawagoe - 独自OS「DaisyOS GB」の紹介
Open Source UN-Conference 2024 Kawagoe - 独自OS「DaisyOS GB」の紹介Yuma Ohgami
 
論文紹介:Automated Classification of Model Errors on ImageNet
論文紹介:Automated Classification of Model Errors on ImageNet論文紹介:Automated Classification of Model Errors on ImageNet
論文紹介:Automated Classification of Model Errors on ImageNetToru Tamaki
 
SOPを理解する 2024/04/19 の勉強会で発表されたものです
SOPを理解する       2024/04/19 の勉強会で発表されたものですSOPを理解する       2024/04/19 の勉強会で発表されたものです
SOPを理解する 2024/04/19 の勉強会で発表されたものですiPride Co., Ltd.
 
論文紹介:Semantic segmentation using Vision Transformers: A survey
論文紹介:Semantic segmentation using Vision Transformers: A survey論文紹介:Semantic segmentation using Vision Transformers: A survey
論文紹介:Semantic segmentation using Vision Transformers: A surveyToru Tamaki
 
スマートフォンを用いた新生児あやし動作の教示システム
スマートフォンを用いた新生児あやし動作の教示システムスマートフォンを用いた新生児あやし動作の教示システム
スマートフォンを用いた新生児あやし動作の教示システムsugiuralab
 
【早稲田AI研究会 講義資料】3DスキャンとTextTo3Dのツールを知ろう!(Vol.1)
【早稲田AI研究会 講義資料】3DスキャンとTextTo3Dのツールを知ろう!(Vol.1)【早稲田AI研究会 講義資料】3DスキャンとTextTo3Dのツールを知ろう!(Vol.1)
【早稲田AI研究会 講義資料】3DスキャンとTextTo3Dのツールを知ろう!(Vol.1)Hiroki Ichikura
 
[DevOpsDays Tokyo 2024] 〜デジタルとアナログのはざまに〜 スマートビルディング爆速開発を支える 自動化テスト戦略
[DevOpsDays Tokyo 2024] 〜デジタルとアナログのはざまに〜 スマートビルディング爆速開発を支える 自動化テスト戦略[DevOpsDays Tokyo 2024] 〜デジタルとアナログのはざまに〜 スマートビルディング爆速開発を支える 自動化テスト戦略
[DevOpsDays Tokyo 2024] 〜デジタルとアナログのはざまに〜 スマートビルディング爆速開発を支える 自動化テスト戦略Ryo Sasaki
 

Recently uploaded (10)

論文紹介:Content-Aware Token Sharing for Efficient Semantic Segmentation With Vis...
論文紹介:Content-Aware Token Sharing for Efficient Semantic Segmentation With Vis...論文紹介:Content-Aware Token Sharing for Efficient Semantic Segmentation With Vis...
論文紹介:Content-Aware Token Sharing for Efficient Semantic Segmentation With Vis...
 
TSAL operation mechanism and circuit diagram.pdf
TSAL operation mechanism and circuit diagram.pdfTSAL operation mechanism and circuit diagram.pdf
TSAL operation mechanism and circuit diagram.pdf
 
Postman LT Fukuoka_Quick Prototype_By Daniel
Postman LT Fukuoka_Quick Prototype_By DanielPostman LT Fukuoka_Quick Prototype_By Daniel
Postman LT Fukuoka_Quick Prototype_By Daniel
 
Open Source UN-Conference 2024 Kawagoe - 独自OS「DaisyOS GB」の紹介
Open Source UN-Conference 2024 Kawagoe - 独自OS「DaisyOS GB」の紹介Open Source UN-Conference 2024 Kawagoe - 独自OS「DaisyOS GB」の紹介
Open Source UN-Conference 2024 Kawagoe - 独自OS「DaisyOS GB」の紹介
 
論文紹介:Automated Classification of Model Errors on ImageNet
論文紹介:Automated Classification of Model Errors on ImageNet論文紹介:Automated Classification of Model Errors on ImageNet
論文紹介:Automated Classification of Model Errors on ImageNet
 
SOPを理解する 2024/04/19 の勉強会で発表されたものです
SOPを理解する       2024/04/19 の勉強会で発表されたものですSOPを理解する       2024/04/19 の勉強会で発表されたものです
SOPを理解する 2024/04/19 の勉強会で発表されたものです
 
論文紹介:Semantic segmentation using Vision Transformers: A survey
論文紹介:Semantic segmentation using Vision Transformers: A survey論文紹介:Semantic segmentation using Vision Transformers: A survey
論文紹介:Semantic segmentation using Vision Transformers: A survey
 
スマートフォンを用いた新生児あやし動作の教示システム
スマートフォンを用いた新生児あやし動作の教示システムスマートフォンを用いた新生児あやし動作の教示システム
スマートフォンを用いた新生児あやし動作の教示システム
 
【早稲田AI研究会 講義資料】3DスキャンとTextTo3Dのツールを知ろう!(Vol.1)
【早稲田AI研究会 講義資料】3DスキャンとTextTo3Dのツールを知ろう!(Vol.1)【早稲田AI研究会 講義資料】3DスキャンとTextTo3Dのツールを知ろう!(Vol.1)
【早稲田AI研究会 講義資料】3DスキャンとTextTo3Dのツールを知ろう!(Vol.1)
 
[DevOpsDays Tokyo 2024] 〜デジタルとアナログのはざまに〜 スマートビルディング爆速開発を支える 自動化テスト戦略
[DevOpsDays Tokyo 2024] 〜デジタルとアナログのはざまに〜 スマートビルディング爆速開発を支える 自動化テスト戦略[DevOpsDays Tokyo 2024] 〜デジタルとアナログのはざまに〜 スマートビルディング爆速開発を支える 自動化テスト戦略
[DevOpsDays Tokyo 2024] 〜デジタルとアナログのはざまに〜 スマートビルディング爆速開発を支える 自動化テスト戦略
 

Featured

How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthThinkNow
 
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfAI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfmarketingartwork
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024Neil Kimberley
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)contently
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024Albert Qian
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsKurio // The Social Media Age(ncy)
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Search Engine Journal
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summarySpeakerHub
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next Tessa Mero
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentLily Ray
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best PracticesVit Horky
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project managementMindGenius
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...RachelPearson36
 
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Applitools
 
12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at WorkGetSmarter
 

Featured (20)

How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
 
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfAI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
 
Skeleton Culture Code
Skeleton Culture CodeSkeleton Culture Code
Skeleton Culture Code
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
 
How to have difficult conversations
How to have difficult conversations How to have difficult conversations
How to have difficult conversations
 
Introduction to Data Science
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data Science
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best Practices
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project management
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
 
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
 
12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work
 
ChatGPT webinar slides
ChatGPT webinar slidesChatGPT webinar slides
ChatGPT webinar slides
 

コード祭り予選突破練習会

  • 1. 今回の問題セットのコンセプト • 基本的に「考察をすると実装が楽になる」のような考 察重視な問題を集めました • たまに「考察をしないとどうしようもない」みたいな問題も • 前半のコード祭り予選過去問については、基本的に 「知っておいたほうがいい問題」を集めました • 8月31日、とかは典型だけど知らないと難しそう • (あとは、なるべく古い問題でかつ配点が100点のもの、 という縛りで選んでいます)
  • 3. A : ダブル文字列 • ちゃんとやっても良いが、与えられた入力を2回出力す るだけで良い • FA : lrmystp (35s)
  • 4. B : とても長い数列 • ついつい順番(何番目にどの数字が来るか)を知りた くなるが、和を求めるだけならどの数字が何回登場す るか、だけ分かれば良い • A_i は 2^(n - i) 回登場する • FA : lrmystp (2m43s)
  • 5. C : 8月31日 • どれを手伝ってもらうのが良いか、というのは「手 伝ってもらったことにより得をする時間」に依存する • つまり、(A_i – B_i) が大きい順に選ぶのが最適 • (A_i – B_i) でソートしてほい • 類題 : この前の夏合宿の1日目のK パンプキン (http://jag2017summer-day1.contest.atcoder.jp/tasks/jag2017summer_day1_k) • FA : lrmystp (7m45s)
  • 6. D : 錬金術士 • 文字列長が 10^5 で一見やばい • 実は、(S1 から最低限使わなきゃいけない文字数)が N以下でかつ(S1 から最大限使える文字数)が N以上 なら錬金可能 • 証明はそこまで難しくない(はず) • あとはちゃんと上の文字数を調べられるか • 各文字が S1, S2 にいくつずつあるかを見れば良い • FA : lrmystp (22m33s)
  • 7. E : 壊れた電車 (1/2) • 最短何分で終わるか知りたいので、二分探索したい気 分になる • T 分しか時間がない場合、左にいる作業員から順番に 「整備していない車両のうち一番左のものまで行き 戻って来る」または「最初右に行き、あるところで 戻ってきて整備していない車両のうち一番左のものま で行く」ということをやらせるのが最適で、それで全 ての車両を網羅できているかを見れば良い
  • 8. E : 壊れた電車 (2/2) • すぐに二分探索が見える問題はもちろん、ぱっと見は 二分探索に見えない問題を二分探索に落とし込んで解 けるようになると良い • もちろんすぐに二分探索に見えるようになるのがベストだが • 類題(?): https://yukicoder.me/problems/no/448 https://yukicoder.me/problems/no/461 • FA : lrmystp (46m01s)
  • 9. F : 登山家 • stack で頑張る(こういうの苦手だから嫌い) • 類問(?): カーペット (http://kupc2013.contest.atcoder.jp/tasks/kupc2013_d) • これもstackで頑張る問題 • これを用いると最大長方形が求まる (http://arc081.contest.atcoder.jp/tasks/arc081_d) • FA : ferin (51m07s) • stack で頑張る(こういうの苦手だから嫌い) • 類問(?): カーペット (http://kupc2013.contest.atcoder.jp/tasks/kupc2013_d) • これもstackで頑張る問題 • これを用いると最大長方形が求まる (http://arc081.contest.atcoder.jp/tasks/arc081_d) • FA : ferin (51m07s)
  • 10. G : 直径 • 2個のグラフの端っこと重心(?) を求める • O(N^2) が間に合うのできつくない • 端と端をつなぐ場合が最長、重心と重心をつなぐ場合 が最短 • 最短の場合、元のグラフの直径の方が大きくてそちらを出力 しなければならない場合があることに注意 • FA : kobae964 (14m32s)
  • 11. H : FA • 結論から言うと、自分がFA を取る問題については、他 の人が解く時間 (B_i) が早い順に解いていくのが最適に なる • その状態から適当に swap してみるとそういう気持ちになる • なので、B_i でソートしてから • dp[今見てる問題][今までの FA の数] := かかった時間のmin • という DP をすると解ける • FA : kobae964(23m07s)
  • 12. I : Be Together • 結論から言うと、(x, y) (x >= 0, y >= 0) にいる人がTター ン後に原点にいられる条件は、 • T * (T + 1) / 2 – (x + y) = (偶数) • となる • 証明は少しむずそう • まずは全ての点の原点からのマンハッタン距離の偶奇が一致して いるかどうかを調べて、あとは一番遠いところとの距離を超えて かつ偶奇が一致するところを見つける • FA : kobae964 (33m24s)
  • 13. J : お釣りの嫌いな高橋君 • こういう問題嫌い(直球) • がっつり桁DP は出なくても、こういう問題なら十分出 る可能性がありそう • 昨日ちょっと書いた感じだと、一つ前の硬貨が10枚以上あったとき、そ れをギリギリまで使う場合と一つ残しておく場合を両方見なきゃいけな くてクソめんどくさそうだった • いくつ繰り上がったかを持ってdpすればいいらしい、なるほど • 類題(?): https://yukicoder.me/problems/no/319 • FA : kobae964 (42m56s)
  • 14. K : 蟻本 • 1個の三角形を作るなら、用いるのは連続する3つの数 に限られる → 2個の場合は? • 連続する3つの数 が2箇所 か、範囲が交差している場合 がある • 1, 1, 2, 2, 5, 5 みたいな • 範囲が交差している場合も、連続する6つの数に限られ る • FA : rickytheta (1h11m59s)