2024-2025 ICPC, NERC, Southern and Volga Russian Regional Contest (Unrated, Online Mirror, ICPC Rules, Preferably Teams)

Solutions are presented as using the least memory and the fastest execution time. It also takes the top 10 most recent solutions from each language. If you want to limit to a specific index, click the "Solved" button and go to that problem.

ContestId
Name
Phase
Frozen
Duration (Seconds)
Relative Time
Start Time
2038 2024-2025 ICPC, NERC, Southern and Volga Russian Regional Contest (Unrated, Online Mirror, ICPC Rules, Preferably Teams) FINISHED False 18000 44479523 Nov. 18, 2024, 10:35 a.m.

Problems

Solved
Index
Name
Type
Tags
Community Tag
Rating
( 7958 ) L Bridge Renovation PROGRAMMING brute force dp greedy math 1400

Recently, Monocarp started working as a director of a park located near his house. The park is quite large, so it even has a small river splitting it into several zones. Several bridges are built across this river. Three of these bridges are especially old and need to be repaired. All three bridges have the same length but differ in width. Their widths are (18), (21) and (25) units, respectively. During the park renovation process, Monocarp has to replace the old planks that served as the surface of the bridges with the new ones. Planks are sold with a standard length of (60) units. Monocarp already knows that he needs (n) planks for each bridge. But since the bridges have different widths, he needs (n) planks of length (18) for the first bridge, (n) planks of length (21) for the second one, and (n) planks of length (25) for the last one. Workers in charge of renovation have no problem with cutting planks into parts but refuse to join planks, since it creates weak spots and looks ugly. Monocarp wants to buy as few planks as possible but struggles to calculate the required number of planks. Can you help him? The first and only line contains a single integer (n) ((1 \le n \le 1000)) — the number of planks required for each of the three bridges. Print a single integer — the minimum number of planks of standard length ((60) units) Monocarp needs to cover all three bridges if the planks can be cut into parts. In the first example, it is possible to cut one plank of length (60) into three planks with lengths (25), (18) and (17), and cut another plank of length (60) into two planks with lengths (39) and (21). That way, Monocarp will have all the required planks.

Tutorials

Submissions

No solutions yet.