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 |
---|---|---|---|---|---|---|
1704 | CodeTON Round 2 (Div. 1 + Div. 2, Rated, Prizes!) | FINISHED | False | 9000 | 72546899 | July 31, 2022, 2:05 p.m. |
Solved$ |
Index |
Name |
Type |
Tags |
Community Tag |
Rating |
---|---|---|---|---|---|---|
( 186 ) | H1 | Game of AI (easy version) | PROGRAMMING | combinatorics fft math |
B"This is the easy version of this problem. The difference between easy and hard versions is the constraint on k and the time limit. Also, in this version of the problem, you only need to calculate the answer when n=k . You can make hacks only if both versions of the problem are solved. Cirno is playing a war simulator game with n towers (numbered from 1 to n ) and n bots (numbered from 1 to n ). The i -th tower is initially occupied by the i -th bot for 1 <= i <= n . Before the game, Cirno first chooses a permutation p = [p_1, p_2, ldots, p_n] of length n (A permutation of length n is an array of length n where each integer between 1 and n appears exactly once). After that, she can choose a sequence a = [a_1, a_2, ldots, a_n] ( 1 <= a_i <= n and a_i ne i for all 1 <= i <= n ). The game has n rounds of attacks. In the i -th round, if the p_i -th bot is still in the game, it will begin its attack, and as the result the a_{p_i} -th tower becomes occupied by the p_i -th bot; the bot that previously occupied the a_{p_i} -th tower will no longer occupy it. If the p_i -th bot is not in the game, nothing will happen in this round. After each round, if a bot doesn't occupy any towers, it will be eliminated and leave the game. Please note that no tower can be occupied by more than one bot, but one bot can occupy more than one tower during the game. At the end of the game, Cirno will record the result as a sequence b = [b_1, b_2, ldots, b_n] , where b_i is the number of the bot that occupies the i -th tower at the end of the game. However, as a mathematics master, she wants you to solve the following counting problem instead of playing games: Count the number of different pairs of sequences a and b that we can get from all possible choices of sequence a and permutation p"... |
CodeTON Round 2 Editorial |
Submission Id |
Author(s) |
Index |
Submitted |
Verdict |
Language |
Test Set |
Tests Passed |
Time taken (ms) |
Memory Consumed (bytes) |
Tags |
Rating |
---|---|---|---|---|---|---|---|---|---|---|---|
166388635 | djq_cpp | H1 | July 31, 2022, 3:40 p.m. | OK | GNU C++14 | TESTS | 20 | 639 | 150732800 | ||
166428312 | hydd | H1 | Aug. 1, 2022, 1:29 a.m. | OK | GNU C++14 | TESTS | 20 | 935 | 416972800 | ||
166392721 | RGB_ICPC1 | H1 | July 31, 2022, 3:59 p.m. | OK | GNU C++14 | TESTS | 20 | 1309 | 200908800 | ||
166390624 | cnnfls_csy | H1 | July 31, 2022, 3:49 p.m. | OK | GNU C++14 | TESTS | 20 | 1700 | 206848000 | ||
166397144 | gamegame | H1 | July 31, 2022, 4:22 p.m. | OK | GNU C++17 | TESTS | 20 | 1013 | 604774400 | ||
166394482 | alireza_kaviani | H1 | July 31, 2022, 4:08 p.m. | OK | GNU C++17 | TESTS | 20 | 1216 | 603545600 | ||
166435957 | qazswedx2 | H1 | Aug. 1, 2022, 3:30 a.m. | OK | GNU C++17 | TESTS | 20 | 1263 | 3584000 | ||
166407984 | JOHNKRAM | H1 | July 31, 2022, 6:30 p.m. | OK | GNU C++17 | TESTS | 20 | 2152 | 3993600 | ||
166427126 | xay5421 | H1 | Aug. 1, 2022, 1:12 a.m. | OK | GNU C++17 (64) | TESTS | 20 | 265 | 102400 | ||
166395394 | WYZFL | H1 | July 31, 2022, 4:12 p.m. | OK | GNU C++17 (64) | TESTS | 20 | 373 | 100454400 | ||
166423496 | orzdevinwang | H1 | July 31, 2022, 11:31 p.m. | OK | GNU C++17 (64) | TESTS | 20 | 670 | 25804800 | ||
166410434 | noimi | H1 | July 31, 2022, 6:58 p.m. | OK | GNU C++17 (64) | TESTS | 20 | 670 | 201011200 | ||
166410387 | noimi | H1 | July 31, 2022, 6:57 p.m. | OK | GNU C++17 (64) | TESTS | 20 | 733 | 201011200 | ||
166394968 | 353cerega | H1 | July 31, 2022, 4:10 p.m. | OK | GNU C++17 (64) | TESTS | 20 | 888 | 150630400 | ||
166405513 | zihouzhong | H1 | July 31, 2022, 6:12 p.m. | OK | GNU C++17 (64) | TESTS | 20 | 967 | 102400 | ||
166398396 | potato167 | H1 | July 31, 2022, 4:27 p.m. | OK | GNU C++17 (64) | TESTS | 20 | 1247 | 201216000 | ||
166393948 | he_____hezhou | H1 | July 31, 2022, 4:05 p.m. | OK | GNU C++17 (64) | TESTS | 20 | 1356 | 0 | ||
166397758 | noimi | H1 | July 31, 2022, 4:24 p.m. | OK | GNU C++17 (64) | TESTS | 20 | 1466 | 201011200 | ||
166416825 | PinkieRabbit | H1 | July 31, 2022, 8:31 p.m. | OK | GNU C++20 (64) | TESTS | 20 | 327 | 25600000 | ||
166407182 | Rubikun | H1 | July 31, 2022, 6:23 p.m. | OK | GNU C++20 (64) | TESTS | 20 | 420 | 200908800 | ||
166395219 | ecnerwala | H1 | July 31, 2022, 4:11 p.m. | OK | GNU C++20 (64) | TESTS | 20 | 686 | 102400 | ||
166408013 | Ormlis | H1 | July 31, 2022, 6:30 p.m. | OK | GNU C++20 (64) | TESTS | 20 | 826 | 1638400 | ||
166430211 | Qingyu | H1 | Aug. 1, 2022, 1:58 a.m. | OK | GNU C++20 (64) | TESTS | 20 | 842 | 204492800 | ||
166399678 | gyh20 | H1 | July 31, 2022, 4:33 p.m. | OK | GNU C++20 (64) | TESTS | 20 | 872 | 205619200 | ||
166393517 | Rebelz | H1 | July 31, 2022, 4:03 p.m. | OK | GNU C++20 (64) | TESTS | 20 | 873 | 224870400 | ||
166395533 | Maksim1744 | H1 | July 31, 2022, 4:13 p.m. | OK | GNU C++20 (64) | TESTS | 20 | 873 | 301772800 | ||
166415047 | A_G | H1 | July 31, 2022, 8 p.m. | OK | GNU C++20 (64) | TESTS | 20 | 888 | 200806400 | ||
166414488 | trainwithoutpain | H1 | July 31, 2022, 7:52 p.m. | OK | GNU C++20 (64) | TESTS | 20 | 889 | 102400 | ||
166408034 | conqueror_of_tourist | H1 | July 31, 2022, 6:30 p.m. | OK | PyPy 3-64 | TESTS | 20 | 670 | 10956800 |
Back to search problems