Upgrade to PRO for Only $50/Year—Limited-Time Offer! 🔥
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
SRM578 解説
Search
tozangezan
May 03, 2013
Programming
0
270
SRM578 解説
tozangezan
May 03, 2013
Tweet
Share
More Decks by tozangezan
See All by tozangezan
SRM573 Div1Hard Div2Hard 解説
tozangezan
1
270
Other Decks in Programming
See All in Programming
Rubyで鍛える仕組み化プロヂュース力
muryoimpl
0
180
tsgolintはいかにしてtypescript-goの非公開APIを呼び出しているのか
syumai
7
2.4k
マスタデータ問題、マイクロサービスでどう解くか
kts
0
130
AI Agent Dojo #4: watsonx Orchestrate ADK体験
oniak3ibm
PRO
0
110
안드로이드 9년차 개발자, 프론트엔드 주니어로 커리어 리셋하기
maryang
1
140
ELYZA_Findy AI Engineering Summit登壇資料_AIコーディング時代に「ちゃんと」やること_toB LLMプロダクト開発舞台裏_20251216
elyza
2
630
開発に寄りそう自動テストの実現
goyoki
2
1.4k
AI前提で考えるiOSアプリのモダナイズ設計
yuukiw00w
0
190
The Past, Present, and Future of Enterprise Java
ivargrimstad
0
370
Basic Architectures
denyspoltorak
0
120
Python札幌 LT資料
t3tra
7
1.1k
脳の「省エネモード」をデバッグする ~System 1(直感)と System 2(論理)の切り替え~
panda728
PRO
0
120
Featured
See All Featured
How to Think Like a Performance Engineer
csswizardry
28
2.4k
Making the Leap to Tech Lead
cromwellryan
135
9.7k
Avoiding the “Bad Training, Faster” Trap in the Age of AI
tmiket
0
38
The Psychology of Web Performance [Beyond Tellerrand 2023]
tammyeverts
49
3.2k
The AI Search Optimization Roadmap by Aleyda Solis
aleyda
1
5k
We Analyzed 250 Million AI Search Results: Here's What I Found
joshbly
0
280
The untapped power of vector embeddings
frankvandijk
1
1.5k
The State of eCommerce SEO: How to Win in Today's Products SERPs - #SEOweek
aleyda
2
9.1k
Testing 201, or: Great Expectations
jmmastey
46
7.8k
Organizational Design Perspectives: An Ontology of Organizational Design Elements
kimpetersen
PRO
0
45
HU Berlin: Industrial-Strength Natural Language Processing with spaCy and Prodigy
inesmontani
PRO
0
110
<Decoding/> the Language of Devs - We Love SEO 2024
nikkihalliwell
0
100
Transcript
SRM 578 Div2 Easy&Hard Div1 Medium 解説 By tozangezan
Div2 Easy (1) これを… N K ret[0]=? ret[1]=?
Div2 Easy (2) こうして… N K ret[0]=max(0,N-K) ret[1]=?
Div2 Easy (3) こうじゃ N K ret[0]=max(0,N-K) ret[1]=N-(K+1)/2
Div2 Hard (1) これを…
Div2 Hard (2) こうして… dp[0] [1] [2] [3] [4] [5]
[6] [7] [8] [9] [10] ... [N+1]
Div2 Hard (3) こうじゃ dp[0] [1] [2] [3] [4] [5]
[6] [7] [8] [9] [10] ... [N+1] dp[3]=dp[0]+dp[1] +dp[2] dp[0]=1 dp[9]=dp[3]+dp[4]+ ...+dp[8] Answer
Div1 Medium (1) これを…
Div1 Medium (2) こうして… dp[last][now]->dp[now][next] (if now->next vaild) At first,
dp[i][j]=1(0<=i<j<=N-1). The answer is (sum of dp[i][j])+N+1
Div1 Medium (2) こうじゃ dp[last][now]->dp[now][next] (if now->next vaild) Valid: interval
[left,right] (left<=last<next<=rig ht) is not exist Calculate valid edge in advance.
The End 右の写真のように、多摩 動物公園にはオオカミが います。