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 |
|---|---|---|---|---|---|---|
| 2022 | Codeforces Round 978 (Div. 2) | FINISHED | False | 7200 | 47557523 | Oct. 13, 2024, 7:35 p.m. |
Solved |
Index |
Name |
Type |
Tags |
Community Tag |
Rating |
|---|---|---|---|---|---|---|
| ( 754 ) | E1 | Billetes MX (Easy Version) | PROGRAMMING | 2-sat binary search combinatorics dfs and similar dsu graphs |
This is the easy version of the problem. In this version, it is guaranteed that (q = 0). You can make hacks only if both versions of the problem are solved. An integer grid (A) with (p) rows and (q) columns is called beautiful if: All elements of the grid are integers between (0) and (2^{30}-1), and For any subgrid, the XOR of the values at the corners is equal to (0). Formally, for any four integers (i_1), (i_2), (j_1), (j_2) ((1 \le i_1 < i_2 \le p); (1 \le j_1 < j_2 \le q)), (A_{i_1, j_1} \oplus A_{i_1, j_2} \oplus A_{i_2, j_1} \oplus A_{i_2, j_2} = 0), where (\oplus) denotes the bitwise XOR operation . There is a partially filled integer grid (G) with (n) rows and (m) columns where only (k) cells are filled. Polycarp wants to know how many ways he can assign integers to the unfilled cells so that the grid is beautiful. However, Monocarp thinks that this problem is too easy. Therefore, he will perform (q) updates on the grid. In each update, he will choose an unfilled cell and assign an integer to it. Note that these updates are persistent . That is, changes made to the grid will apply when processing future updates. For each of the (q + 1) states of the grid, the initial state and after each of the (q) queries, determine the number of ways Polycarp can assign integers to the unfilled cells so that the grid is beautiful. Since this number can be very large, you are only required to output their values modulo (10^9+7). The first line contains (t) ((1 \le t \le 10^4)) — the number of test cases. The first line of each test case contains four integers (n), (m), (k) and (q) ((2 \le n, m \le 10^5); (0 \le k \le 10^5); (q = 0)) — the number of rows, the number of columns, the number of fixed cells, and the number of updates. The following (k) lines contain three integers (r), (c) and (v) ($$$1 \le r \le n, 1 \le c \le |
| Codeforces Round 978 (Div 2) Editorial |
Submission Id |
Author(s) |
Index |
Submitted |
Verdict |
Language |
Test Set |
Tests Passed |
Time taken (ms) |
Memory Consumed (bytes) |
Tags |
Rating |
|---|---|---|---|---|---|---|---|---|---|---|---|
| 285760026 | niquefa_diego | E1 | Oct. 14, 2024, 3:48 a.m. | OK | C# 10 | TESTS | 30 | 233 | 19353600 | ||
| 285733822 | lxhgww | E1 | Oct. 13, 2024, 9:13 p.m. | OK | C++17 (GCC 7-32) | TESTS | 30 | 139 | 3276800 | ||
| 285734262 | Kilani | E1 | Oct. 13, 2024, 9:14 p.m. | OK | C++17 (GCC 7-32) | TESTS | 30 | 156 | 3686400 | ||
| 285753337 | Luvidi | E1 | Oct. 14, 2024, 2:05 a.m. | OK | C++17 (GCC 7-32) | TESTS | 30 | 156 | 5734400 | ||
| 285735538 | moonpole | E1 | Oct. 13, 2024, 9:19 p.m. | OK | C++17 (GCC 7-32) | TESTS | 30 | 171 | 4915200 | ||
| 285742745 | FattyPenguin | E1 | Oct. 13, 2024, 10:13 p.m. | OK | C++17 (GCC 7-32) | TESTS | 30 | 186 | 80179200 | ||
| 285743265 | FzArK | E1 | Oct. 13, 2024, 10:20 p.m. | OK | C++17 (GCC 7-32) | TESTS | 30 | 187 | 8908800 | ||
| 285739039 | KingOfThisWorld | E1 | Oct. 13, 2024, 9:31 p.m. | OK | C++17 (GCC 7-32) | TESTS | 30 | 296 | 1843200 | ||
| 285768921 | candy0014 | E1 | Oct. 14, 2024, 5:38 a.m. | OK | C++17 (GCC 7-32) | TESTS | 30 | 311 | 80179200 | ||
| 285739101 | mayankzach | E1 | Oct. 13, 2024, 9:31 p.m. | OK | C++17 (GCC 7-32) | TESTS | 30 | 312 | 102400 | ||
| 285762137 | tloinuy | E1 | Oct. 14, 2024, 4:17 a.m. | OK | C++17 (GCC 7-32) | TESTS | 30 | 312 | 5120000 | ||
| 285754598 | ssk4988 | E1 | Oct. 14, 2024, 2:24 a.m. | OK | C++20 (GCC 13-64) | TESTS | 30 | 108 | 102400 | ||
| 285769272 | yyyz04 | E1 | Oct. 14, 2024, 5:42 a.m. | OK | C++20 (GCC 13-64) | TESTS | 30 | 108 | 2457600 | ||
| 285743373 | qusol | E1 | Oct. 13, 2024, 10:21 p.m. | OK | C++20 (GCC 13-64) | TESTS | 30 | 109 | 2457600 | ||
| 285751127 | JoanhLan | E1 | Oct. 14, 2024, 1:25 a.m. | OK | C++20 (GCC 13-64) | TESTS | 30 | 109 | 7475200 | ||
| 285735267 | DanTheMan. | E1 | Oct. 13, 2024, 9:18 p.m. | OK | C++20 (GCC 13-64) | TESTS | 30 | 124 | 102400 | ||
| 285731751 | StarSilk | E1 | Oct. 13, 2024, 9:05 p.m. | OK | C++20 (GCC 13-64) | TESTS | 30 | 124 | 4096000 | ||
| 285760495 | zjdl | E1 | Oct. 14, 2024, 3:54 a.m. | OK | C++20 (GCC 13-64) | TESTS | 30 | 140 | 13516800 | ||
| 285740224 | anhkha1004 | E1 | Oct. 13, 2024, 9:34 p.m. | OK | C++20 (GCC 13-64) | TESTS | 30 | 140 | 14745600 | ||
| 285765511 | Beaboss | E1 | Oct. 14, 2024, 4:59 a.m. | OK | C++20 (GCC 13-64) | TESTS | 30 | 140 | 16896000 | ||
| 285730466 | bleeding | E1 | Oct. 13, 2024, 9:01 p.m. | OK | C++20 (GCC 13-64) | TESTS | 30 | 171 | 5427200 | ||
| 285762769 | N29 | E1 | Oct. 14, 2024, 4:26 a.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 30 | 93 | 4915200 | ||
| 285753475 | lcyxds | E1 | Oct. 14, 2024, 2:07 a.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 30 | 109 | 1024000 | ||
| 285744358 | Zeyush | E1 | Oct. 13, 2024, 10:36 p.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 30 | 124 | 4812800 | ||
| 285732352 | jeroenodb | E1 | Oct. 13, 2024, 9:07 p.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 30 | 155 | 102400 | ||
| 285742174 | sojabhai | E1 | Oct. 13, 2024, 10:08 p.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 30 | 171 | 102400 | ||
| 285754968 | Abdullah500 | E1 | Oct. 14, 2024, 2:29 a.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 30 | 186 | 21504000 | ||
| 285747708 | towrist | E1 | Oct. 14, 2024, 12:04 a.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 30 | 187 | 24883200 | ||
| 285736831 | Timka_programist | E1 | Oct. 13, 2024, 9:23 p.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 30 | 203 | 8294400 | ||
| 285737089 | shisukenohara | E1 | Oct. 13, 2024, 9:24 p.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 30 | 218 | 102400 | ||
| 285730893 | TheMyth | E1 | Oct. 13, 2024, 9:02 p.m. | OK | C++23 (GCC 14-64, msys2) | TESTS | 30 | 234 | 102400 | ||
| 285758561 | arnabmanna | E1 | Oct. 14, 2024, 3:26 a.m. | OK | Java 21 | TESTS | 30 | 467 | 1945600 | ||
| 285747728 | profchi | E1 | Oct. 14, 2024, 12:04 a.m. | OK | Java 8 | TESTS | 30 | 358 | 19456000 | ||
| 285743074 | vwxyz0 | E1 | Oct. 13, 2024, 10:18 p.m. | OK | PyPy 3-64 | TESTS | 30 | 718 | 45465600 | ||
| 285728318 | tassei903 | E1 | Oct. 13, 2024, 8:53 p.m. | OK | PyPy 3-64 | TESTS | 30 | 749 | 20787200 | ||
| 285736460 | alexwice | E1 | Oct. 13, 2024, 9:22 p.m. | OK | PyPy 3-64 | TESTS | 30 | 905 | 167116800 | ||
| 285729464 | golomb | E1 | Oct. 13, 2024, 8:57 p.m. | OK | PyPy 3-64 | TESTS | 30 | 968 | 70656000 |
Back to search problems