Problem 2922 --3.4.4 Raucous Rockers

2922: 3.4.4 Raucous Rockers

"
Time Limit $1$ 秒/Second(s) Memory Limit $512$ 兆字节/Megabyte(s)
提交总数 $2$ 正确数量 $2$
裁判形式 标准裁判/Standard Judge 我的状态 尚未尝试
难度 分类标签 usaco

You just inherited the rights to N (1 <= N <= 20) previously unreleased songs recorded by the popular group Raucous Rockers. You plan to release a set of M (1 <= M <= 20) compact disks with a selection of these songs. Each disk can hold a maximum of T (1 <= T <= 20) minutes of music, and a song can not overlap from one disk to another.

Since you are a classical music fan and have no way to judge the artistic merits of these songs, you decide on the following criteria for making the selection:

  • The songs on the set of disks must appear in the order of the dates that they were written. 
  • The total number of songs included will be maximized. 
Line 1: Three integers: N, T, and M.
Line 2: N integers that are the lengths of the songs ordered by the date they were written.
A single line with an integer that is the number of songs that will fit on M disks.

4 5 2
4 3 4 2
3

推荐代码 查看2922 所有题解 上传题解视频得图灵币

本题记录 用 户(点击查看用户) 运行号(点击购买题解) 时 间
算法最快[$0 $ms] 梦尘 695328 2020-12-30 23:58:00
内存最少[$2024 $KB] 梦尘 695328 2020-12-30 23:58:00
第一AC 淡意的温柔 596655 2020-06-12 17:18:37
第一挑战 淡意的温柔 596655 2020-06-12 17:18:37

赛题来源/所属竞赛 usaco training usaco Training

竞赛编号 竞赛名称 竞赛时间 访问比赛