随笔分类 - DP
摘要:Problem Statement Taro's summer vacation starts tomorrow, and he has decided to make plans for it now. The vacation consists of NN days. For each ii (
阅读全文
摘要:Problem Statement There are NN stones, numbered 1,2,…,N1,2,…,N. For each ii (1≤i≤N1≤i≤N), the height of Stone ii is hihi. There is a frog who is initi
阅读全文
摘要:There are nn models in the shop numbered from 11 to nn, with sizes s1,s2,…,sns1,s2,…,sn. Orac will buy some of the models and will arrange them in the
阅读全文
摘要:Denis, after buying flowers and sweets (you will learn about this story in the next task), went to a date with Nastya to ask her to become a couple. N
阅读全文
摘要:This is the hard version of this problem. The only difference is the constraint on kk — the number of gifts in the offer. In this version: 2≤k≤n2≤k≤n.
阅读全文
摘要:You are given two integers nn and mm. Calculate the number of pairs of arrays (a,b)(a,b) such that: the length of both arrays is equal to mm; each ele
阅读全文

浙公网安备 33010602011771号