Codeforces Round 641 (Div. 1)

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
1349 Codeforces Round 641 (Div. 1) FINISHED False 9000 142536299 May 12, 2020, 12:35 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 4543 ) C Orac and Game of Life PROGRAMMING dfs and similar graphs implementation shortest paths 2000

B'Please notice the unusual memory limit of this problem. Orac likes games. Recently he came up with the new game, "Game of Life". You should play this game on a black and white grid with n rows and m columns. Each cell is either black or white. For each iteration of the game (the initial iteration is 0 ), the color of each cell will change under the following rules: Two cells are adjacent if they have a mutual edge. Now Orac has set an initial situation, and he wants to know for the cell (i,j) (in i -th row and j -th column), what will be its color at the iteration p . He may ask you these questions several times. The first line contains three integers n,m,t (1 <= n,m <= 1000, 1 <= t <= 100 ,000) , representing the number of rows, columns, and the number of Orac queries. Each of the following n lines contains a binary string of length m , the j -th character in i -th line represents the initial color of cell (i,j) . '0 ' stands for white, '1 ' stands for black. Each of the following t lines contains three integers i,j,p (1 <= i <= n, 1 <= j <= m, 1 <= p <= 10^{18}) , representing a query from Orac. Print t lines, in i -th line you should print the answer to the i -th query by Orac. If the color of this cell is black, you should print '1 '; otherwise, you should write '0 '. For the first example, the picture above shows the initial situation and the color of cells at the iteration 1 , 2 , and 3 . We can see that the color of (1,1) at the iteration 1 is black, the color of (2,2) at the iteration 2 is black, and the color of (3,3) at the iteration 3 is also black. For the second example, you can prove that the cells will never change their colors. '...

Tutorials

Codeforces Round #641 Editorial

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
79873003 Gassa C May 12, 2020, 2:17 p.m. OK D TESTS 53 249 30515200 2000
80283351 _DAG_ C May 16, 2020, 6:07 a.m. OK GNU C++11 TESTS 53 62 21094400 2000
79876451 dqa2020 C May 12, 2020, 2:25 p.m. OK GNU C++11 TESTS 53 78 13824000 2000
79872633 Frame233 C May 12, 2020, 2:16 p.m. OK GNU C++11 TESTS 53 78 17100800 2000
79838886 LJC00118 C May 12, 2020, 1:06 p.m. OK GNU C++11 TESTS 53 78 17100800 2000
79988777 echo7919 C May 13, 2020, 2:20 p.m. OK GNU C++11 TESTS 53 78 17305600 2000
80215861 luogu_bot2 C May 15, 2020, 10:45 a.m. OK GNU C++11 TESTS 53 78 20172800 2000
79856568 shuyingte C May 12, 2020, 1:39 p.m. OK GNU C++11 TESTS 53 78 21196800 2000
79929608 CYJian C May 13, 2020, 12:02 a.m. OK GNU C++11 TESTS 53 78 21708800 2000
80071241 chdyFZH C May 14, 2020, 1 p.m. OK GNU C++11 TESTS 53 78 25292800 2000
79936936 froggyzhang C May 13, 2020, 3:11 a.m. OK GNU C++11 TESTS 53 78 28364800 2000
79844764 NotaMotuaQAQ C May 12, 2020, 1:16 p.m. OK GNU C++14 TESTS 53 62 14233600 2000
79859184 11235813213455 C May 12, 2020, 1:45 p.m. OK GNU C++14 TESTS 53 109 30208000 2000
80074418 rdd6584 C May 14, 2020, 1:38 p.m. OK GNU C++14 TESTS 53 124 12902400 2000
79913630 tanmay2625 C May 12, 2020, 6:27 p.m. OK GNU C++14 TESTS 53 124 12902400 2000
80673998 bl964131617 C May 19, 2020, 9:41 a.m. OK GNU C++14 TESTS 53 124 13414400 2000
80778370 I_love_Myself_ C May 20, 2020, 1:54 p.m. OK GNU C++14 TESTS 53 124 16588800 2000
80224351 ezoilearner C May 15, 2020, 12:24 p.m. OK GNU C++14 TESTS 53 124 16793600 2000
79924052 lsantire C May 12, 2020, 9:10 p.m. OK GNU C++14 TESTS 53 124 16998400 2000
79869024 schtomi97 C May 12, 2020, 2:07 p.m. OK GNU C++14 TESTS 53 124 16998400 2000
79883208 Kirito C May 12, 2020, 2:42 p.m. OK GNU C++14 TESTS 53 124 17100800 2000
79933610 HatsuneMikuo C May 13, 2020, 1:53 a.m. OK GNU C++17 TESTS 53 92 29900800 2000
79870770 HatsuneMikuo C May 12, 2020, 2:11 p.m. OK GNU C++17 TESTS 53 93 30105600 2000
79945649 nickluo C May 13, 2020, 5:47 a.m. OK GNU C++17 TESTS 53 109 24678400 2000
79879615 limbo.null C May 12, 2020, 2:33 p.m. OK GNU C++17 TESTS 53 109 29593600 2000
81370838 chauhan176 C May 25, 2020, 10:10 a.m. OK GNU C++17 TESTS 53 124 14028800 2000
80648728 gs15120 C May 19, 2020, 2:17 a.m. OK GNU C++17 TESTS 53 124 14028800 2000
79886149 Bennettz C May 12, 2020, 2:49 p.m. OK GNU C++17 TESTS 53 124 14131200 2000
81602822 mintCHILL C May 27, 2020, 9:32 a.m. OK GNU C++17 TESTS 53 124 15052800 2000
79858015 KonaeAkira C May 12, 2020, 1:42 p.m. OK GNU C++17 TESTS 53 124 16998400 2000
79856206 jumpmelon C May 12, 2020, 1:39 p.m. OK GNU C++17 TESTS 53 124 16998400 2000
79939136 liouzhou_101 C May 13, 2020, 3:56 a.m. OK GNU C++17 (64) TESTS 53 62 20172800 2000
79840565 Egor C May 12, 2020, 1:08 p.m. OK GNU C++17 (64) TESTS 53 93 18022400 2000
80179605 kessido C May 14, 2020, 11:28 p.m. OK GNU C++17 (64) TESTS 53 93 26726400 2000
79933612 interestingLSY C May 13, 2020, 1:53 a.m. OK GNU C++17 (64) TESTS 53 93 30822400 2000
79877034 Oxygen. C May 12, 2020, 2:26 p.m. OK GNU C++17 (64) TESTS 53 109 11980800 2000
79902455 zjsdut C May 12, 2020, 4:32 p.m. OK GNU C++17 (64) TESTS 53 109 12697600 2000
80028716 iefnah06 C May 14, 2020, 3:41 a.m. OK GNU C++17 (64) TESTS 53 109 13004800 2000
81335715 bmu C May 24, 2020, 10:44 p.m. OK GNU C++17 (64) TESTS 53 109 14745600 2000
79889156 harshit1729 C May 12, 2020, 2:56 p.m. OK GNU C++17 (64) TESTS 53 109 15462400 2000
79896885 Siberian C May 12, 2020, 3:53 p.m. OK GNU C++17 (64) TESTS 53 109 18124800 2000
79857431 cirno3153 C May 12, 2020, 1:41 p.m. OK Java 11 TESTS 53 295 30310400 2000
79859526 uwi C May 12, 2020, 1:45 p.m. OK Java 11 TESTS 53 343 29286400 2000
79886208 awesomelemonade C May 12, 2020, 2:49 p.m. OK Java 11 TESTS 53 514 50995200 2000
79989403 TheSawan C May 13, 2020, 2:26 p.m. OK Java 11 TESTS 53 935 134246400 2000
79946603 aman28rwt C May 13, 2020, 6 a.m. OK Java 8 TESTS 53 171 34508800 2000
79948041 aman28rwt C May 13, 2020, 6:18 a.m. OK Java 8 TESTS 53 186 34508800 2000
79859054 DarLam C May 12, 2020, 1:44 p.m. OK Java 8 TESTS 53 233 44236800 2000
79858946 fetetriste C May 12, 2020, 1:44 p.m. OK Java 8 TESTS 53 248 43008000 2000
79919852 ijxjdjd C May 12, 2020, 7:54 p.m. OK Java 8 TESTS 53 358 70860800 2000
79872837 Xylenox C May 12, 2020, 2:16 p.m. OK Java 8 TESTS 53 358 80691200 2000
79873858 Taran_1407 C May 12, 2020, 2:19 p.m. OK Java 8 TESTS 53 374 33382400 2000
79913886 MagentaCobra C May 12, 2020, 6:30 p.m. OK Java 8 TESTS 53 374 94924800 2000
79846141 SecondThread C May 12, 2020, 1:18 p.m. OK Java 8 TESTS 53 405 88473600 2000
80537633 yaoct C May 17, 2020, 4:18 p.m. OK Java 8 TESTS 53 405 110182400 2000
79999514 yakamoto C May 13, 2020, 4:06 p.m. OK Kotlin TESTS 53 436 33792000 2000
79849924 Tlatoani C May 12, 2020, 1:26 p.m. OK Kotlin TESTS 53 639 134246400 2000
79896665 koboshi C May 12, 2020, 3:52 p.m. OK Kotlin TESTS 53 716 134246400 2000
79885555 mban259 C May 12, 2020, 2:47 p.m. OK Mono C# TESTS 53 311 45260800 2000
79879069 hibatibati C May 12, 2020, 2:31 p.m. OK Mono C# TESTS 53 327 32768000 2000
79862343 keymoon C May 12, 2020, 1:52 p.m. OK Mono C# TESTS 53 389 47206400 2000
80273233 yinyun C May 16, 2020, 2:51 a.m. OK MS C++ TESTS 53 218 24371200 2000
80248459 vjudge2 C May 15, 2020, 5:14 p.m. OK MS C++ TESTS 53 467 42905600 2000
80264659 Parshvajain25 C May 15, 2020, 9:40 p.m. OK MS C++ 2017 TESTS 53 171 20889600 2000
79866310 pichulia C May 12, 2020, 2:01 p.m. OK MS C++ 2017 TESTS 53 186 18022400 2000
79861947 tarattata1 C May 12, 2020, 1:51 p.m. OK MS C++ 2017 TESTS 53 187 27033600 2000
79945140 P___ C May 13, 2020, 5:39 a.m. OK MS C++ 2017 TESTS 53 234 38092800 2000
80886484 Najmus_Sakib_Rashid C May 21, 2020, 8:22 p.m. OK MS C++ 2017 TESTS 53 249 44646400 2000
80847373 Kirill456Z C May 21, 2020, 11:36 a.m. OK MS C++ 2017 TESTS 53 265 10649600 2000
79964699 BpeMeHHa91_TryDHocTb C May 13, 2020, 9:43 a.m. OK MS C++ 2017 TESTS 53 358 40345600 2000
79893172 Pasqual45 C May 12, 2020, 3:04 p.m. OK MS C++ 2017 TESTS 53 733 30105600 2000
79886139 alex_36 C May 12, 2020, 2:49 p.m. OK MS C++ 2017 TESTS 53 1326 22118400 2000
79888077 ZloyNegr C May 12, 2020, 2:54 p.m. OK MS C++ 2017 TESTS 53 1466 68608000 2000
79859408 pajenegod C May 12, 2020, 1:45 p.m. OK PyPy 2 TESTS 53 592 69222400 2000
79882660 alexwice C May 12, 2020, 2:40 p.m. OK PyPy 2 TESTS 53 873 130662400 2000
79887819 MVP C May 12, 2020, 2:53 p.m. OK PyPy 2 TESTS 53 888 82329600 2000
79851615 bcollet C May 12, 2020, 1:29 p.m. OK PyPy 2 TESTS 53 997 90112000 2000
79879558 wattaihei C May 12, 2020, 2:33 p.m. OK PyPy 3 TESTS 53 685 83660800 2000
80425597 SaDaiJin C May 17, 2020, 2:23 a.m. OK PyPy 3 TESTS 53 779 51814400 2000
79866280 Kiri8128 C May 12, 2020, 2 p.m. OK PyPy 3 TESTS 53 780 51814400 2000
79860256 tamato C May 12, 2020, 1:47 p.m. OK PyPy 3 TESTS 53 811 47001600 2000
80627121 silentone C May 18, 2020, 5:28 p.m. OK PyPy 3 TESTS 53 842 66355200 2000
79865955 pineriver C May 12, 2020, 2 p.m. OK PyPy 3 TESTS 53 904 88268800 2000
79871872 mkawa2 C May 12, 2020, 2:14 p.m. OK PyPy 3 TESTS 53 951 63385600 2000
79873688 titia C May 12, 2020, 2:18 p.m. OK PyPy 3 TESTS 53 1013 85196800 2000
79933237 throwawayatcoder C May 13, 2020, 1:44 a.m. OK PyPy 3 TESTS 53 1123 100864000 2000
79889245 malylesio C May 12, 2020, 2:56 p.m. OK PyPy 3 TESTS 53 1248 133222400 2000
79854575 sansen C May 12, 2020, 1:35 p.m. OK Rust TESTS 53 155 45568000 2000
79880734 cotton100pc C May 12, 2020, 2:35 p.m. OK Rust TESTS 53 156 34918400 2000

remove filters

Back to search problems