Codeforces Round 785 (Div. 2)

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
1673 Codeforces Round 785 (Div. 2) FINISHED False 7200 80493899 April 30, 2022, 2:35 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 840 ) F Anti-Theft Road Planning PROGRAMMING bitmasks constructive algorithms divide and conquer greedy interactive math

B"This is an interactive problem. A city has n^2 buildings divided into a grid of n rows and n columns. You need to build a road of some length D(A,B) of your choice between each pair of adjacent by side buildings A and B . Due to budget limitations and legal restrictions, the length of each road must be a positive integer and the total length of all roads should not exceed 48 ,000 . There is a thief in the city who will start from the topmost, leftmost building (in the first row and the first column) and roam around the city, occasionally stealing artifacts from some of the buildings. He can move from one building to another adjacent building by travelling through the road which connects them. You are unable to track down what buildings he visits and what path he follows to reach them. But there is one tracking mechanism in the city. The tracker is capable of storing a single integer x which is initially 0 . Each time the thief travels from a building A to another adjacent building B through a road of length D(A,B) , the tracker changes x to x oplus D(A,B) . Each time the thief steals from a building, the tracker reports the value x stored in it and resets it back to 0 . It is known beforehand that the thief will steal in exactly k buildings but you will know the values returned by the tracker only after the thefts actually happen. Your task is to choose the lengths of roads in such a way that no matter what strategy or routes the thief follows, you will be able to exactly tell the location of all the buildings where the thefts occurred from the values returned by the tracker. First read a single line containing two integers n (2 <= q n <= q 32) and k (1 <= q k <= q 1024) denoting the number of rows and number of thefts respectively. Let's denote the j -th building in the i -th row by B_{i,j} . Then print n lines each cont"...

Tutorials

Codeforces Round #785 (Div. 2) Editorial

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
155468133 Chenyu_Qiu F May 1, 2022, 1:55 a.m. OK GNU C++14 TESTS 160 30 0
155434627 dlalswp25 F April 30, 2022, 4:06 p.m. OK GNU C++14 TESTS 160 30 0
155471091 paul2008 F May 1, 2022, 3:13 a.m. OK GNU C++14 TESTS 160 30 102400
155454944 Charbel F April 30, 2022, 7:28 p.m. OK GNU C++14 TESTS 160 30 204800
155476320 Phantasy F May 1, 2022, 5 a.m. OK GNU C++14 TESTS 160 31 0
155475622 F99_ll_H21 F May 1, 2022, 4:47 a.m. OK GNU C++14 TESTS 160 31 0
155473019 cqbzdj F May 1, 2022, 3:57 a.m. OK GNU C++14 TESTS 160 31 0
155471019 Big_gold_date F May 1, 2022, 3:11 a.m. OK GNU C++14 TESTS 160 31 0
155465641 zltzlt F May 1, 2022, 12:34 a.m. OK GNU C++14 TESTS 160 31 0
155464997 _chess_ F May 1, 2022, 12:13 a.m. OK GNU C++14 TESTS 160 31 0
155453720 alex.y0675 F April 30, 2022, 7:06 p.m. OK GNU C++17 TESTS 160 30 0
155433714 HappyPacMan F April 30, 2022, 4:03 p.m. OK GNU C++17 TESTS 160 30 0
155445390 roflanbanan F April 30, 2022, 5:11 p.m. OK GNU C++17 TESTS 160 30 204800
155444270 qqqqc F April 30, 2022, 5:02 p.m. OK GNU C++17 TESTS 160 30 204800
155448651 vanwij F April 30, 2022, 5:46 p.m. OK GNU C++17 TESTS 160 30 307200
155479823 rajkon F May 1, 2022, 5:52 a.m. OK GNU C++17 TESTS 160 31 0
155478062 Fatma_Abdelhamed F May 1, 2022, 5:28 a.m. OK GNU C++17 TESTS 160 31 0
155470794 Fairy_Tale F May 1, 2022, 3:06 a.m. OK GNU C++17 TESTS 160 31 0
155468393 HappyPacMan F May 1, 2022, 2:04 a.m. OK GNU C++17 TESTS 160 31 0
155467996 ButterCake F May 1, 2022, 1:51 a.m. OK GNU C++17 TESTS 160 31 0
155440893 Kude F April 30, 2022, 4:30 p.m. OK GNU C++17 (64) TESTS 160 15 102400
155444916 MtSaka F April 30, 2022, 5:08 p.m. OK GNU C++17 (64) TESTS 160 30 0
155444754 Sana F April 30, 2022, 5:06 p.m. OK GNU C++17 (64) TESTS 160 30 0
155438098 CaiLiyi F April 30, 2022, 4:20 p.m. OK GNU C++17 (64) TESTS 160 30 0
155434126 natsugiri F April 30, 2022, 4:04 p.m. OK GNU C++17 (64) TESTS 160 30 0
155435744 MateoCV F April 30, 2022, 4:10 p.m. OK GNU C++17 (64) TESTS 160 30 102400
155478708 SanweiTreap F May 1, 2022, 5:37 a.m. OK GNU C++17 (64) TESTS 160 31 0
155473392 BigHeadMonster F May 1, 2022, 4:05 a.m. OK GNU C++17 (64) TESTS 160 31 0
155469752 Bolshevik F May 1, 2022, 2:40 a.m. OK GNU C++17 (64) TESTS 160 31 0
155461685 DavitMarg F April 30, 2022, 10:14 p.m. OK GNU C++17 (64) TESTS 160 31 0
155437736 fr200110217102 F April 30, 2022, 4:18 p.m. OK GNU C++20 (64) TESTS 160 15 0
155444143 ytkn F April 30, 2022, 5:01 p.m. OK GNU C++20 (64) TESTS 160 15 307200
155469840 DeadlyPillow F May 1, 2022, 2:43 a.m. OK GNU C++20 (64) TESTS 160 30 0
155452590 komeiji_koishi514 F April 30, 2022, 6:47 p.m. OK GNU C++20 (64) TESTS 160 30 0
155448843 Kotoblepass F April 30, 2022, 5:49 p.m. OK GNU C++20 (64) TESTS 160 30 0
155444515 huagaohan F April 30, 2022, 5:04 p.m. OK GNU C++20 (64) TESTS 160 30 0
155444150 Kira_1234 F April 30, 2022, 5:01 p.m. OK GNU C++20 (64) TESTS 160 30 0
155478959 Solitary_Walker F May 1, 2022, 5:40 a.m. OK GNU C++20 (64) TESTS 160 30 102400
155448821 lrvideckis F April 30, 2022, 5:48 p.m. OK GNU C++20 (64) TESTS 160 30 102400
155431638 S2speed F April 30, 2022, 3:55 p.m. OK GNU C++20 (64) TESTS 160 30 716800
155438714 golions F April 30, 2022, 4:22 p.m. OK Java 8 TESTS 160 186 0
155433289 Beduardo F April 30, 2022, 4:01 p.m. OK Kotlin 1.4 TESTS 160 186 102400
155440440 machine_solution F April 30, 2022, 4:29 p.m. OK MS C++ 2017 TESTS 160 46 204800
155454406 taiga0629 F April 30, 2022, 7:18 p.m. OK PyPy 3 TESTS 160 202 4505600
155443433 misorin F April 30, 2022, 4:57 p.m. OK PyPy 3 TESTS 160 249 5632000
155440425 Igrmi F April 30, 2022, 4:29 p.m. OK PyPy 3-64 TESTS 160 170 6656000
155439907 SPD_9X2 F April 30, 2022, 4:27 p.m. OK PyPy 3-64 TESTS 160 171 3379200
155431054 xlk F April 30, 2022, 3:53 p.m. OK PyPy 3-64 TESTS 160 171 8601600
155443995 ulyabelyaeva F April 30, 2022, 5 p.m. OK PyPy 3-64 TESTS 160 202 6451200
155435905 nobrakes F April 30, 2022, 4:11 p.m. OK PyPy 3-64 TESTS 160 390 11059200
155434740 Genius3435 F April 30, 2022, 4:07 p.m. OK Python 3 TESTS 160 93 0
155466444 clause F May 1, 2022, 1:01 a.m. OK Rust 2021 TESTS 160 46 0

remove filters

Back to search problems