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 |
---|---|---|---|---|---|---|
1290 | Codeforces Round 616 (Div. 1) | FINISHED | False | 9000 | 151170899 | Feb. 2, 2020, 2:05 p.m. |
Solved$ |
Index |
Name |
Type |
Tags |
Community Tag |
Rating |
---|---|---|---|---|---|---|
( 5508 ) | B | Irreducible Anagrams | PROGRAMMING | binary search constructive algorithms data structures strings two pointers | 1900 |
B'Let 's call two strings s and t anagrams of each other if it is possible to rearrange symbols in the string s to get a string, equal to t . Let 's consider two strings s and t which are anagrams of each other. We say that t is a reducible anagram of s if there exists an integer k ge 2 and 2k non-empty strings s_1, t_1, s_2, t_2, ... , s_k, t_k that satisfy the following conditions: If such strings don 't exist, then t is said to be an irreducible anagram of s . Note that these notions are only defined when s and t are anagrams of each other. For example, consider the string s = "gamegame". Then the string t = "megamage" is a reducible anagram of s , we may choose for example s_1 = "game", s_2 = "gam", s_3 = "e" and t_1 = "mega", t_2 = "mag", t_3 = "e": On the other hand, we can prove that t = "memegaga" is an irreducible anagram of s . You will be given a string s and q queries, represented by two integers 1 <= l <= r <= |s| (where |s| is equal to the length of the string s ). For each query, you should find if the substring of s formed by characters from the l -th to the r -th has at least one irreducible anagram. The first line contains a string s , consisting of lowercase English characters ( 1 <= |s| <= 2 cdot 10^5 ). The second line contains a single integer q ( 1 <= q <= 10^5 ) -- the number of queries. Each of the following q lines contain two integers l and r ( 1 <= l <= r <= |s| ), representing a query for the substring of s formed by characters from the l -th to the r -th. For each query, print a single line containing "Yes" (without quotes) if the corresponding substring has at least one irreducible anagram, and a single line containing "No" (without quotes) otherwise. In th'... |
Codeforces Round #616 Editorial |
Submission Id |
Author(s) |
Index |
Submitted |
Verdict |
Language |
Test Set |
Tests Passed |
Time taken (ms) |
Memory Consumed (bytes) |
Tags |
Rating |
---|---|---|---|---|---|---|---|---|---|---|---|
70041401 | Gassa | B | Feb. 2, 2020, 2:21 p.m. | OK | D | TESTS | 47 | 140 | 42086400 | 1900 | |
70040879 | hos.lyric | B | Feb. 2, 2020, 2:20 p.m. | OK | D | TESTS | 47 | 187 | 35840000 | 1900 | |
70059793 | physics0523 | B | Feb. 2, 2020, 3:03 p.m. | OK | GNU C11 | TESTS | 47 | 390 | 27545600 | 1900 | |
70056131 | idxcalcal | B | Feb. 2, 2020, 2:53 p.m. | OK | GNU C++11 | TESTS | 47 | 46 | 21299200 | 1900 | |
70065515 | AutumnKite | B | Feb. 2, 2020, 3:20 p.m. | OK | GNU C++11 | TESTS | 47 | 46 | 37683200 | 1900 | |
70108472 | nantf | B | Feb. 3, 2020, 4:27 a.m. | OK | GNU C++11 | TESTS | 48 | 61 | 21094400 | 1900 | |
70047094 | ohweonfire | B | Feb. 2, 2020, 2:32 p.m. | OK | GNU C++11 | TESTS | 47 | 61 | 21094400 | 1900 | |
70344690 | TYGZ | B | Feb. 5, 2020, 9:20 a.m. | OK | GNU C++11 | TESTS | 48 | 61 | 21094400 | 1900 | |
70213919 | xht37 | B | Feb. 4, 2020, 9:07 a.m. | OK | GNU C++11 | TESTS | 48 | 61 | 25292800 | 1900 | |
70534801 | zlczlc | B | Feb. 8, 2020, 2:13 a.m. | OK | GNU C++11 | TESTS | 48 | 61 | 25702400 | 1900 | |
70059941 | disangan233 | B | Feb. 2, 2020, 3:03 p.m. | OK | GNU C++11 | TESTS | 47 | 61 | 29491200 | 1900 | |
70822948 | Taday | B | Feb. 12, 2020, 5 a.m. | OK | GNU C++11 | TESTS | 48 | 61 | 36352000 | 1900 | |
70202141 | Binary_Search_Tree | B | Feb. 4, 2020, 4:44 a.m. | OK | GNU C++11 | TESTS | 48 | 61 | 105267200 | 1900 | |
70213557 | apoorv17 | B | Feb. 4, 2020, 9 a.m. | OK | GNU C++14 | TESTS | 48 | 78 | 18534400 | 1900 | |
70827368 | aakk | B | Feb. 12, 2020, 6:58 a.m. | OK | GNU C++14 | TESTS | 48 | 78 | 21811200 | 1900 | |
70093882 | MYNAMEISSHARIFUL | B | Feb. 2, 2020, 7:24 p.m. | OK | GNU C++14 | TESTS | 48 | 92 | 21094400 | 1900 | |
70079291 | espr1t | B | Feb. 2, 2020, 4:14 p.m. | OK | GNU C++14 | TESTS | 47 | 92 | 21094400 | 1900 | |
70119156 | Sturdy | B | Feb. 3, 2020, 8:08 a.m. | OK | GNU C++14 | TESTS | 48 | 93 | 2560000 | 1900 | |
70058450 | FastestFinger | B | Feb. 2, 2020, 2:59 p.m. | OK | GNU C++14 | TESTS | 47 | 93 | 2560000 | 1900 | |
70414828 | Jian_Ron | B | Feb. 6, 2020, 6:43 a.m. | OK | GNU C++14 | TESTS | 48 | 93 | 4198400 | 1900 | |
70088960 | oridya_fan | B | Feb. 2, 2020, 5:47 p.m. | OK | GNU C++14 | TESTS | 48 | 93 | 21094400 | 1900 | |
70821466 | vjudge4 | B | Feb. 12, 2020, 4:06 a.m. | OK | GNU C++14 | TESTS | 48 | 93 | 21094400 | 1900 | |
70374515 | Nson | B | Feb. 5, 2020, 4:01 p.m. | OK | GNU C++14 | TESTS | 48 | 93 | 21094400 | 1900 | |
70474140 | lavin | B | Feb. 7, 2020, 2:41 a.m. | OK | GNU C++17 | TESTS | 48 | 77 | 21811200 | 1900 | |
70050112 | p6pou | B | Feb. 2, 2020, 2:38 p.m. | OK | GNU C++17 | TESTS | 47 | 78 | 21094400 | 1900 | |
70103162 | Snowe | B | Feb. 3, 2020, 1:20 a.m. | OK | GNU C++17 | TESTS | 48 | 78 | 22118400 | 1900 | |
70046826 | JOHNKRAM | B | Feb. 2, 2020, 2:31 p.m. | OK | GNU C++17 | TESTS | 47 | 78 | 23142400 | 1900 | |
70050006 | interestingLSY | B | Feb. 2, 2020, 2:38 p.m. | OK | GNU C++17 | TESTS | 47 | 78 | 36249600 | 1900 | |
70347631 | xiao_tu_zhi | B | Feb. 5, 2020, 10 a.m. | OK | GNU C++17 | TESTS | 48 | 93 | 2252800 | 1900 | |
70453112 | limabeans | B | Feb. 6, 2020, 4:49 p.m. | OK | GNU C++17 | TESTS | 48 | 93 | 2560000 | 1900 | |
70083695 | GKT1 | B | Feb. 2, 2020, 4:32 p.m. | OK | GNU C++17 | TESTS | 47 | 93 | 3788800 | 1900 | |
70343160 | Vergil | B | Feb. 5, 2020, 8:56 a.m. | OK | GNU C++17 | TESTS | 48 | 93 | 8192000 | 1900 | |
70361172 | vjudge5 | B | Feb. 5, 2020, 1:18 p.m. | OK | GNU C++17 | TESTS | 48 | 93 | 20992000 | 1900 | |
70091341 | synapse | B | Feb. 2, 2020, 6:29 p.m. | OK | Go | TESTS | 48 | 233 | 4608000 | 1900 | |
70239644 | ZeyadKhattab | B | Feb. 4, 2020, 2:25 p.m. | OK | Java 11 | TESTS | 48 | 311 | 33792000 | 1900 | |
70050418 | qwerty787788 | B | Feb. 2, 2020, 2:39 p.m. | OK | Java 11 | TESTS | 47 | 327 | 33792000 | 1900 | |
70056136 | Suzukaze | B | Feb. 2, 2020, 2:53 p.m. | OK | Java 11 | TESTS | 47 | 342 | 18841600 | 1900 | |
70089903 | JustAndreyka | B | Feb. 2, 2020, 6:02 p.m. | OK | Java 11 | TESTS | 48 | 732 | 144076800 | 1900 | |
70313580 | Kita_The_Dragon | B | Feb. 4, 2020, 8:02 p.m. | OK | Java 11 | TESTS | 48 | 1107 | 42700800 | 1900 | |
70313168 | Kita_The_Dragon | B | Feb. 4, 2020, 7:52 p.m. | OK | Java 11 | TESTS | 48 | 1356 | 44646400 | 1900 | |
70056129 | cwise | B | Feb. 2, 2020, 2:53 p.m. | OK | Java 8 | TESTS | 47 | 218 | 46796800 | 1900 | |
70054616 | AnandOza | B | Feb. 2, 2020, 2:49 p.m. | OK | Java 8 | TESTS | 47 | 233 | 32768000 | 1900 | |
70047827 | uwi | B | Feb. 2, 2020, 2:33 p.m. | OK | Java 8 | TESTS | 47 | 248 | 31846400 | 1900 | |
70090122 | Taran_1407 | B | Feb. 2, 2020, 6:06 p.m. | OK | Java 8 | TESTS | 48 | 249 | 31948800 | 1900 | |
70560944 | beroul | B | Feb. 8, 2020, 11:51 a.m. | OK | Java 8 | TESTS | 48 | 249 | 32665600 | 1900 | |
70578105 | abhinav_002 | B | Feb. 8, 2020, 4:23 p.m. | OK | Java 8 | TESTS | 48 | 249 | 38297600 | 1900 | |
70467613 | flyingpurplepeopleeater | B | Feb. 6, 2020, 9:17 p.m. | OK | Java 8 | TESTS | 48 | 249 | 38297600 | 1900 | |
70072627 | YahiaSherif | B | Feb. 2, 2020, 3:46 p.m. | OK | Java 8 | TESTS | 47 | 249 | 41472000 | 1900 | |
70047941 | travm12 | B | Feb. 2, 2020, 2:34 p.m. | OK | Java 8 | TESTS | 47 | 264 | 17305600 | 1900 | |
70155174 | polyakoff | B | Feb. 3, 2020, 1:53 p.m. | OK | Java 8 | TESTS | 48 | 264 | 41369600 | 1900 | |
70052584 | Tlatoani | B | Feb. 2, 2020, 2:44 p.m. | OK | Kotlin | TESTS | 47 | 187 | 2764800 | 1900 | |
70053712 | darnley | B | Feb. 2, 2020, 2:47 p.m. | OK | Kotlin | TESTS | 47 | 1466 | 198451200 | 1900 | |
70135162 | darnley | B | Feb. 3, 2020, 11:33 a.m. | OK | Kotlin | TESTS | 48 | 1544 | 208486400 | 1900 | |
70054806 | ngtkana | B | Feb. 2, 2020, 2:50 p.m. | OK | Mono C# | TESTS | 47 | 608 | 29184000 | 1900 | |
70066757 | tarattata1 | B | Feb. 2, 2020, 3:25 p.m. | OK | MS C++ | TESTS | 47 | 78 | 21094400 | 1900 | |
70083130 | lxhgww | B | Feb. 2, 2020, 4:30 p.m. | OK | MS C++ | TESTS | 47 | 93 | 21094400 | 1900 | |
70620160 | vjudge3 | B | Feb. 9, 2020, 11:16 a.m. | OK | MS C++ | TESTS | 48 | 108 | 24268800 | 1900 | |
70058834 | math957963 | B | Feb. 2, 2020, 3 p.m. | OK | MS C++ | TESTS | 47 | 202 | 21094400 | 1900 | |
70804330 | vjudge5 | B | Feb. 11, 2020, 5:54 p.m. | OK | MS C++ | TESTS | 48 | 514 | 24473600 | 1900 | |
70074151 | P___ | B | Feb. 2, 2020, 3:52 p.m. | OK | MS C++ 2017 | TESTS | 47 | 109 | 24268800 | 1900 | |
70066040 | pichulia | B | Feb. 2, 2020, 3:22 p.m. | OK | MS C++ 2017 | TESTS | 47 | 109 | 24268800 | 1900 | |
70770939 | vjudge4 | B | Feb. 11, 2020, 7 a.m. | OK | MS C++ 2017 | TESTS | 48 | 124 | 24268800 | 1900 | |
70094592 | AleksanderBalobanov | B | Feb. 2, 2020, 7:41 p.m. | OK | MS C++ 2017 | TESTS | 48 | 124 | 31846400 | 1900 | |
70061861 | youx | B | Feb. 2, 2020, 3:09 p.m. | OK | MS C++ 2017 | TESTS | 47 | 140 | 21196800 | 1900 | |
70086733 | wp32pw | B | Feb. 2, 2020, 5:15 p.m. | OK | MS C++ 2017 | TESTS | 48 | 311 | 105062400 | 1900 | |
70064547 | vpike | B | Feb. 2, 2020, 3:17 p.m. | OK | MS C++ 2017 | TESTS | 47 | 390 | 21504000 | 1900 | |
70066796 | Timonnable | B | Feb. 2, 2020, 3:25 p.m. | OK | MS C++ 2017 | TESTS | 47 | 546 | 22323200 | 1900 | |
70715057 | vjudge3 | B | Feb. 10, 2020, 8:15 a.m. | OK | MS C++ 2017 | TESTS | 48 | 748 | 24985600 | 1900 | |
70042396 | Eva | B | Feb. 2, 2020, 2:23 p.m. | OK | Node.js | TESTS | 47 | 1278 | 58572800 | 1900 | |
70065091 | pajenegod | B | Feb. 2, 2020, 3:19 p.m. | OK | PyPy 2 | TESTS | 47 | 311 | 45977600 | 1900 | |
70116075 | EM1NEM | B | Feb. 3, 2020, 7:14 a.m. | OK | PyPy 2 | TESTS | 48 | 389 | 28160000 | 1900 | |
70116012 | vjudge1 | B | Feb. 3, 2020, 7:13 a.m. | OK | PyPy 2 | TESTS | 48 | 404 | 28160000 | 1900 | |
70060320 | pineriver | B | Feb. 2, 2020, 3:04 p.m. | OK | PyPy 3 | TESTS | 47 | 607 | 42188800 | 1900 | |
70072992 | nagitaosu | B | Feb. 2, 2020, 3:48 p.m. | OK | PyPy 3 | TESTS | 47 | 638 | 32460800 | 1900 | |
70064097 | titia | B | Feb. 2, 2020, 3:16 p.m. | OK | PyPy 3 | TESTS | 47 | 638 | 44851200 | 1900 | |
70064594 | macaroni | B | Feb. 2, 2020, 3:17 p.m. | OK | PyPy 3 | TESTS | 47 | 654 | 48435200 | 1900 | |
70069491 | Kiri8128 | B | Feb. 2, 2020, 3:34 p.m. | OK | PyPy 3 | TESTS | 47 | 764 | 49459200 | 1900 | |
70087307 | FireBird23 | B | Feb. 2, 2020, 5:22 p.m. | OK | PyPy 3 | TESTS | 48 | 1372 | 118886400 | 1900 | |
70196357 | mkawa2 | B | Feb. 4, 2020, 12:33 a.m. | OK | PyPy 3 | TESTS | 48 | 1622 | 40140800 | 1900 | |
70099964 | SinKing | B | Feb. 2, 2020, 10:31 p.m. | OK | PyPy 3 | TESTS | 48 | 1638 | 40652800 | 1900 | |
70187862 | julianferres | B | Feb. 3, 2020, 11:26 p.m. | OK | PyPy 3 | TESTS | 48 | 1699 | 40652800 | 1900 | |
70422690 | vjudge3 | B | Feb. 6, 2020, 9:13 a.m. | OK | PyPy 3 | TESTS | 48 | 1777 | 50995200 | 1900 | |
70062781 | nwi | B | Feb. 2, 2020, 3:12 p.m. | OK | Python 2 | TESTS | 47 | 935 | 61337600 | 1900 | |
70065098 | sansen | B | Feb. 2, 2020, 3:19 p.m. | OK | Rust | TESTS | 47 | 124 | 25395200 | 1900 |
Back to search problems