摘要:
链接 http://acm.hdu.edu.cn/showproblem.php?pid=6376 分析 这道题好像不是很难,因为是要拼出前缀1,所以确定剪下每一段1需要的刀数,然后因为有次数限制,所以这个问题实际上相当于一个01背包问题,体积换价值,头部和尾部的话需要一刀,中间两刀,但中间的1有一 阅读全文
摘要:
Welcome to Innopolis city. Throughout the whole year, Innopolis citizens suffer from everlasting city construction. From the window in your room, you 阅读全文
摘要:
You’ve got a string a1,a2,…,an, consisting of zeros and ones.Let’s call a sequence of consecutive elements ai,ai + 1,…, aj (1≤ i≤ j≤ n) a substring of 阅读全文
摘要:
Problem Description There is a pile of n wooden sticks. The length and weight of each stick are known in advance. The sticks are to be processed by a 阅读全文