TypeDB Forces 2023 (Div. 1 + Div. 2, Rated, Prizes!)

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
1787 TypeDB Forces 2023 (Div. 1 + Div. 2, Rated, Prizes!) FINISHED False 10800 62263463 Jan. 29, 2023, 2:35 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 241 ) H Codeforces Scoreboard PROGRAMMING data structures dp ternary search

B"You are participating in a Codeforces Round with n problems. You spend exactly one minute to solve each problem, the time it takes to submit a problem can be ignored. You can only solve at most one problem at any time. The contest starts at time 0 , so you can make your first submission at any time t ge 1 minutes. Whenever you submit a problem, it is always accepted. The scoring of the i -th problem can be represented by three integers k_i , b_i , and a_i . If you solve it at time t minutes, you get max(b_i - k_i cdot t,a_i) points. Your task is to choose an order to solve all these n problems to get the maximum possible score. You can assume the contest is long enough to solve all problems. Each test contains multiple test cases. The first line contains an integer t ( 1 <= t <= 10^4 ) -- the number of test cases. The first line of each test case contains one integer n ( 1 <= n <= 2 cdot 10^5 ) -- the number of problems. The n lines follow, the i -th of them contains three integers k_i , b_i , a_i ( 1 <= k_i,b_i,a_i <= 10^9 ; a_i < b_i ), denoting that you get the score of max(b_i - k_i cdot t,a_i) if you solve the i -th task at time t minutes. It's guaranteed that the sum of n does not exceed 2 cdot 10^5 . For each test case, print a line containing a single integer -- the maximum score you can get. In the second test case, the points for all problems at each minute are listed below. The points displayed in red denote one of the optimal orders with the score 53 . "...

Tutorials

TypeDB Forces 2023 (Div. 1 + Div. 2, Rated, Prizes!) Editorial

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
191170603 rainboy H Jan. 29, 2023, 6:50 p.m. OK GNU C11 TESTS 58 234 8806400
191206679 jiangtaizhe001 H Jan. 30, 2023, 5:19 a.m. OK GNU C++14 TESTS 60 452 7987200
191156908 emptyhope H Jan. 29, 2023, 5:04 p.m. OK GNU C++14 TESTS 58 1777 20889600
191170406 Noam527 H Jan. 29, 2023, 6:49 p.m. OK GNU C++14 TESTS 58 2667 21708800
191158917 hos.lyric H Jan. 29, 2023, 5:14 p.m. OK GNU C++17 TESTS 58 358 17612800
191199058 lxyzlz1 H Jan. 30, 2023, 3:12 a.m. OK GNU C++17 TESTS 60 405 26112000
191174934 Chenyu_Qiu H Jan. 29, 2023, 7:30 p.m. OK GNU C++17 TESTS 58 1778 17612800
191155682 Benq H Jan. 29, 2023, 4:58 p.m. OK GNU C++17 (64) TESTS 58 265 19558400
191161147 Bolshevik H Jan. 29, 2023, 5:24 p.m. OK GNU C++17 (64) TESTS 58 514 8806400
191194250 Kubic H Jan. 30, 2023, 1:41 a.m. OK GNU C++17 (64) TESTS 60 514 26112000
191161050 yosupo H Jan. 29, 2023, 5:24 p.m. OK GNU C++17 (64) TESTS 58 639 11776000
191149572 WYZFL H Jan. 29, 2023, 4:29 p.m. OK GNU C++17 (64) TESTS 58 794 11980800
191146913 zihouzhong H Jan. 29, 2023, 4:18 p.m. OK GNU C++17 (64) TESTS 58 1247 12800000
191170183 353cerega H Jan. 29, 2023, 6:47 p.m. OK GNU C++17 (64) TESTS 58 1653 3379200
191187510 Qwerty1232 H Jan. 29, 2023, 10:38 p.m. OK GNU C++20 (64) TESTS 58 124 5632000
191187522 Qwerty1232 H Jan. 29, 2023, 10:38 p.m. OK GNU C++20 (64) TESTS 58 140 5632000
191186977 Qwerty1232 H Jan. 29, 2023, 10:27 p.m. OK GNU C++20 (64) TESTS 58 140 5632000
191187532 Qwerty1232 H Jan. 29, 2023, 10:39 p.m. OK GNU C++20 (64) TESTS 58 140 5632000
191150263 jiangly H Jan. 29, 2023, 4:32 p.m. OK GNU C++20 (64) TESTS 58 202 17817600
191170544 brunovsky H Jan. 29, 2023, 6:50 p.m. OK GNU C++20 (64) TESTS 58 202 25600000
191156328 Ormlis H Jan. 29, 2023, 5:01 p.m. OK GNU C++20 (64) TESTS 58 234 16179200
191161539 Qwerty1232 H Jan. 29, 2023, 5:26 p.m. OK GNU C++20 (64) TESTS 58 249 4812800
191182230 Qwerty1232 H Jan. 29, 2023, 9:02 p.m. OK GNU C++20 (64) TESTS 58 249 5632000
191194998 platelet H Jan. 30, 2023, 1:57 a.m. OK GNU C++20 (64) TESTS 60 280 9625600

remove filters

Back to search problems