Codeforces Round 1083 (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
2205 Codeforces Round 1083 (Div. 2) FINISHED False 9000 4289123 Feb. 26, 2026, 2:35 p.m.

Problems

Solved
Index
Name
Type
Tags
Community Tag
Rating
( 7436 ) C Simons and Posting Blogs PROGRAMMING greedy sortings

There are (n) blogs. The (i)-th blog mentioned (l_i) users in order as an array (a_i=a_{i,1},a_{i,2},\ldots,a_{i,l_i}). You are going to post all (n) blogs. Let us maintain a sequence (Q) that describes the list of users you have recently mentioned. You need to perform the following operation exactly (n) times: Choose an unposted blog (i) ((1\le i\le n)), then post it. This will cause the following operations for each (1\le j\le l_i) in order: If (a_{i,j}) already exists in (Q), then move (a_{i,j}) to the beginning of (Q). Otherwise, insert (a_{i,j}) at the beginning of (Q). If (a_{i,j}) already exists in (Q), then move (a_{i,j}) to the beginning of (Q). Otherwise, insert (a_{i,j}) at the beginning of (Q). Find the lexicographically smallest(^{\text{∗}}) (Q) after all (n) operations. (^{\text{∗}})An array (x) is lexicographically smaller than an array (y) if and only if one of the following holds: (x) is a prefix of (y), but (x \ne y); or in the first position where (x) and (y) differ, the array (x) has a smaller element than the corresponding element in (y). Each test contains multiple test cases. The first line contains the number of test cases (t) ((1 \le t \le 1000)). The description of the test cases follows. The first line contains a single integer (n) ((1\le n\le 3000)) — the number of blogs. Then (n) lines follow, the (i)-th line starting with an integer (l_i) ((1\le l_i\le 3000)), describing the number of users mentioned in the (i)-th blog, which is followed by (l_i) integers (a_{i,1},a_{i,2},\ldots,a_{i,l_i}) ((1\le a_{i,j}\le 10^6)) — the list of users mentioned in the (i)-th blog. It is guaranteed that the sum of (n) over all test cases does not exceed (3000). Denote (\sum\limits_{i=1}^n l_i) as (L). It is guaranteed that the sum of $$$L$

Tutorials

Tutorial

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
364553983 wanna_be_cs_gaoshou C Feb. 26, 2026, 7:11 p.m. OK C# 13 TESTS 13 343 16384000
364556281 wanna_be_cs_gaoshou C Feb. 26, 2026, 7:37 p.m. OK C# 13 TESTS 13 375 3584000
364554879 wanna_be_cs_gaoshou C Feb. 26, 2026, 7:21 p.m. OK C# 13 TESTS 13 375 15974400
364551933 wanna_be_cs_gaoshou C Feb. 26, 2026, 6:48 p.m. OK C# 13 TESTS 13 406 16281600
364537623 wanna_be_cs_gaoshou C Feb. 26, 2026, 4:44 p.m. OK C# 13 TESTS 13 1937 14336000
364546616 wanna_be_cs_gaoshou C Feb. 26, 2026, 5:59 p.m. OK C# 13 TESTS 13 1953 20070400
364579324 VaiseIamHere C Feb. 27, 2026, 2:46 a.m. OK C++17 (GCC 7-32) TESTS 13 46 0
364538828 dbg1 C Feb. 26, 2026, 4:49 p.m. OK C++17 (GCC 7-32) TESTS 13 46 0
364524829 Aeon C Feb. 26, 2026, 3:51 p.m. OK C++17 (GCC 7-32) TESTS 13 46 0
364540393 Relen231 C Feb. 26, 2026, 4:56 p.m. OK C++17 (GCC 7-32) TESTS 13 46 102400
364535687 feng_tian2 C Feb. 26, 2026, 4:35 p.m. OK C++17 (GCC 7-32) TESTS 13 46 102400
364530905 xfnode C Feb. 26, 2026, 4:14 p.m. OK C++17 (GCC 7-32) TESTS 13 46 102400
364525920 Nekan C Feb. 26, 2026, 3:55 p.m. OK C++17 (GCC 7-32) TESTS 13 46 1024000
364524511 nbufe2422230033 C Feb. 26, 2026, 3:50 p.m. OK C++17 (GCC 7-32) TESTS 13 46 1024000
364522981 Vii33 C Feb. 26, 2026, 3:45 p.m. OK C++17 (GCC 7-32) TESTS 13 46 2048000
364535736 tanmay_amritkar C Feb. 26, 2026, 4:35 p.m. OK C++17 (GCC 7-32) TESTS 13 46 4198400
364525745 stasbadzi2 C Feb. 26, 2026, 3:54 p.m. OK C++20 (GCC 13-64) TESTS 13 31 102400
364525017 Konnor132 C Feb. 26, 2026, 3:52 p.m. OK C++20 (GCC 13-64) TESTS 13 46 0
364537840 kabhimanyu C Feb. 26, 2026, 4:44 p.m. OK C++20 (GCC 13-64) TESTS 13 46 102400
364534700 suryanshubansal C Feb. 26, 2026, 4:30 p.m. OK C++20 (GCC 13-64) TESTS 13 46 102400
364529333 MikasAck C Feb. 26, 2026, 4:07 p.m. OK C++20 (GCC 13-64) TESTS 13 46 102400
364525268 T__f C Feb. 26, 2026, 3:53 p.m. OK C++20 (GCC 13-64) TESTS 13 46 102400
364567343 Nobody479 C Feb. 26, 2026, 9:59 p.m. OK C++20 (GCC 13-64) TESTS 13 46 204800
364525491 t6stks C Feb. 26, 2026, 3:54 p.m. OK C++20 (GCC 13-64) TESTS 13 46 204800
364565188 sushant4599 C Feb. 26, 2026, 9:23 p.m. OK C++20 (GCC 13-64) TESTS 13 46 1024000
364562915 sushant4599 C Feb. 26, 2026, 8:52 p.m. OK C++20 (GCC 13-64) TESTS 13 46 1024000
364557072 Sahil_Deo C Feb. 26, 2026, 7:46 p.m. OK C++23 (GCC 14-64, msys2) TESTS 13 31 0
364546490 xiaogan882 C Feb. 26, 2026, 5:58 p.m. OK C++23 (GCC 14-64, msys2) TESTS 13 31 1024000
364537460 Bors__ C Feb. 26, 2026, 4:43 p.m. OK C++23 (GCC 14-64, msys2) TESTS 13 31 9011200
364530927 Iam_6_Feet C Feb. 26, 2026, 4:14 p.m. OK C++23 (GCC 14-64, msys2) TESTS 13 31 11264000
364527590 xvl_ C Feb. 26, 2026, 4:01 p.m. OK C++23 (GCC 14-64, msys2) TESTS 13 31 37273600
364576475 NagnipNuyoah C Feb. 27, 2026, 1:48 a.m. OK C++23 (GCC 14-64, msys2) TESTS 13 46 0
364556891 Sahil_Deo C Feb. 26, 2026, 7:44 p.m. OK C++23 (GCC 14-64, msys2) TESTS 13 46 0
364553884 Nickson C Feb. 26, 2026, 7:10 p.m. OK C++23 (GCC 14-64, msys2) TESTS 13 46 0
364550674 jiangly C Feb. 26, 2026, 6:34 p.m. OK C++23 (GCC 14-64, msys2) TESTS 13 46 0
364540451 nameless_coder C Feb. 26, 2026, 4:56 p.m. OK C++23 (GCC 14-64, msys2) TESTS 13 46 0
364531033 actualtsg C Feb. 26, 2026, 4:14 p.m. OK GNU C11 TESTS 13 46 4505600
364538273 1435730 C Feb. 26, 2026, 4:46 p.m. OK GNU C11 TESTS 13 93 72192000
364583478 chethan_coding C Feb. 27, 2026, 4:02 a.m. OK Go TESTS 13 125 4915200
364533533 testtest111ksjfrdvn C Feb. 26, 2026, 4:25 p.m. OK Java 21 TESTS 13 218 1126400
364541800 ziko_ahmed C Feb. 26, 2026, 5:01 p.m. OK Java 21 TESTS 13 250 6451200
364522361 Snigdha67 C Feb. 26, 2026, 3:43 p.m. OK Java 21 TESTS 13 296 512000
364535217 suraj_006 C Feb. 26, 2026, 4:33 p.m. OK Java 21 TESTS 13 312 1740800
364529858 UlaanBatat C Feb. 26, 2026, 4:09 p.m. OK Java 21 TESTS 13 328 716800
364535503 __0xCk__ C Feb. 26, 2026, 4:34 p.m. OK Java 21 TESTS 13 343 819200
364533354 UlianaKhodaeva C Feb. 26, 2026, 4:24 p.m. OK Java 21 TESTS 13 343 1433600
364528453 Ninja_1705 C Feb. 26, 2026, 4:04 p.m. OK Java 21 TESTS 13 343 6963200
364528452 888krishnam C Feb. 26, 2026, 4:04 p.m. OK Java 21 TESTS 13 359 614400
364550289 Azad_Singh C Feb. 26, 2026, 6:30 p.m. OK Java 21 TESTS 13 375 716800
364525058 Vivek_Shahi C Feb. 26, 2026, 3:52 p.m. OK Java 8 TESTS 13 359 0
364552614 letscod2021 C Feb. 26, 2026, 6:56 p.m. OK Java 8 TESTS 13 437 0
364532169 Algo_blaster007 C Feb. 26, 2026, 4:19 p.m. OK Java 8 TESTS 13 437 0
364533760 vv12388 C Feb. 26, 2026, 4:26 p.m. OK Java 8 TESTS 13 484 0
364523064 kevin_0911 C Feb. 26, 2026, 3:46 p.m. OK Java 8 TESTS 13 515 0
364541277 gangadhar_017 C Feb. 26, 2026, 5 p.m. OK Java 8 TESTS 13 578 0
364542185 kunnathradhesh C Feb. 26, 2026, 5:03 p.m. OK Java 8 TESTS 13 609 0
364530743 Karthikeya__00 C Feb. 26, 2026, 4:13 p.m. OK Java 8 TESTS 13 609 0
364525964 jehankumar C Feb. 26, 2026, 3:55 p.m. OK Java 8 TESTS 13 640 0
364533866 arunavjtoti C Feb. 26, 2026, 4:26 p.m. OK Java 8 TESTS 13 843 0
364536868 Hanlabong C Feb. 26, 2026, 4:40 p.m. OK Kotlin 1.9 TESTS 13 343 512000
364533278 nigarr_rafiyeva_123 C Feb. 26, 2026, 4:24 p.m. OK Kotlin 1.9 TESTS 13 531 0
364528440 yg.margo C Feb. 26, 2026, 4:04 p.m. OK Kotlin 2.2 TESTS 13 218 24166400
364534794 xxxtentaclez C Feb. 26, 2026, 4:30 p.m. OK Kotlin 2.2 TESTS 13 984 25190400
364531886 chinesedfan C Feb. 26, 2026, 4:18 p.m. OK Node.js TESTS 13 531 35840000
364554957 kumoRin C Feb. 26, 2026, 7:21 p.m. OK Node.js TESTS 13 546 35430400
364559910 PrathamB_math C Feb. 26, 2026, 8:17 p.m. OK PyPy 3 TESTS 13 546 8294400
364537065 lushfeast C Feb. 26, 2026, 4:41 p.m. OK PyPy 3 TESTS 13 718 8908800
364531965 Mantavya21 C Feb. 26, 2026, 4:18 p.m. OK PyPy 3 TESTS 13 734 11366400
364525521 Kandarp C Feb. 26, 2026, 3:54 p.m. OK PyPy 3 TESTS 13 796 5427200
364527252 shrey767 C Feb. 26, 2026, 4 p.m. OK PyPy 3 TESTS 13 828 12083200
364527345 sharokku C Feb. 26, 2026, 4 p.m. OK PyPy 3 TESTS 13 968 5939200
364537672 Nikrien C Feb. 26, 2026, 4:44 p.m. OK PyPy 3-64 TESTS 13 250 4198400
364548636 Akshar_7 C Feb. 26, 2026, 6:16 p.m. OK PyPy 3-64 TESTS 13 265 4096000
364531569 adityagiri3600 C Feb. 26, 2026, 4:17 p.m. OK PyPy 3-64 TESTS 13 296 6860800
364531169 _WeakestXDreamer_ C Feb. 26, 2026, 4:15 p.m. OK PyPy 3-64 TESTS 13 343 4812800
364534554 HNA.Myuu C Feb. 26, 2026, 4:29 p.m. OK PyPy 3-64 TESTS 13 343 12492800
364535832 abhiiify C Feb. 26, 2026, 4:35 p.m. OK PyPy 3-64 TESTS 13 343 15769600
364525584 michael3437 C Feb. 26, 2026, 3:54 p.m. OK PyPy 3-64 TESTS 13 375 3481600
364534625 NaughtyIndia C Feb. 26, 2026, 4:30 p.m. OK PyPy 3-64 TESTS 13 375 5632000
364531097 xor2004 C Feb. 26, 2026, 4:15 p.m. OK PyPy 3-64 TESTS 13 375 7884800
364525582 rohansaipabba C Feb. 26, 2026, 3:54 p.m. OK PyPy 3-64 TESTS 13 406 7987200
364532852 SaraZeynalzada C Feb. 26, 2026, 4:22 p.m. OK Python 2 TESTS 13 1359 102400
364531617 _Nivas_ C Feb. 26, 2026, 4:17 p.m. OK Python 3 TESTS 13 78 2048000
364583391 VertinWithOrange C Feb. 27, 2026, 4 a.m. OK Python 3 TESTS 13 406 1126400
364530985 Kanish974677 C Feb. 26, 2026, 4:14 p.m. OK Python 3 TESTS 13 875 1536000
364531733 PrathameshParit C Feb. 26, 2026, 4:17 p.m. OK Python 3 TESTS 13 937 1433600
364528588 dnikhilsuraj5 C Feb. 26, 2026, 4:05 p.m. OK Python 3 TESTS 13 953 1433600
364531116 riaz2001 C Feb. 26, 2026, 4:15 p.m. OK Python 3 TESTS 13 968 1433600
364526103 tuanduong C Feb. 26, 2026, 3:56 p.m. OK Python 3 TESTS 13 1000 1740800
364531134 LisniakRoman C Feb. 26, 2026, 4:15 p.m. OK Python 3 TESTS 13 1015 1638400
364534472 the_7g_girl C Feb. 26, 2026, 4:29 p.m. OK Python 3 TESTS 13 1296 1433600
364526896 Tuchmos C Feb. 26, 2026, 3:58 p.m. OK Python 3 TESTS 13 1312 1536000
364587461 Spheniscine C Feb. 27, 2026, 5:14 a.m. OK Rust 2021 TESTS 13 46 102400
364523086 sridharan_53 C Feb. 26, 2026, 3:46 p.m. OK Rust 2021 TESTS 13 625 102400
364524192 ymy202602 C Feb. 26, 2026, 3:49 p.m. OK Scala TESTS 13 1718 409600

remove filters

Back to search problems