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.
Problems
B'This is an interactive problem. After completing the last level of the enchanted temple, you received a powerful artifact of the 255th level. Do not rush to celebrate, because this artifact has a powerful rune that can be destroyed with a single spell s , which you are going to find. We define the spell as some non-empty string consisting only of the letters a and b. At any time, you can cast an arbitrary non-empty spell t , and the rune on the artifact will begin to resist. Resistance of the rune is the edit distance between the strings that specify the casted spell t and the rune-destroying spell s . Edit distance of two strings s and t is a value equal to the minimum number of one-character operations of replacing, inserting and deleting characters in s to get t . For example, the distance between ababa and aaa is 2 , the distance between aaa and aba is 1 , the distance between bbaba and abb is 3 . The edit distance is 0 if and only if the strings are equal. It is also worth considering that the artifact has a resistance limit -- if you cast more than n + 2 spells, where n is the length of spell s , the rune will be blocked. Thus, it takes n + 2 or fewer spells to destroy the rune that is on your artifact. Keep in mind that the required destructive spell s must also be counted among these n + 2 spells. Note that the length n of the rune-destroying spell s is not known to you in advance. It is only known that its length n does not exceed 300 . Interaction is happening through queries. Each request consists of a single non-empty string t -- the spell you want to cast. The length of string t should not exceed 300 . Each string should consist only of the letters a and b. In response to the query, you will get resistance runes -- the edit distance between the strings that specify the casted spell t and th'... |
Tutorials
Submissions
Submission Id |
Author(s) |
Index |
Submitted |
Verdict |
Language |
Test Set |
Tests Passed |
Time taken (ms) |
Memory Consumed (bytes) |
Tags |
Rating |
67543047 |
Chipe1 |
D |
Dec. 24, 2019, 3:35 p.m. |
OK |
GNU C11 |
TESTS |
77 |
31 |
0 |
|
2300 |
67570725 |
FE40536 |
D |
Dec. 24, 2019, 9:56 p.m. |
OK |
GNU C11 |
TESTS |
77 |
31 |
0 |
|
2300 |
68098069 |
QuisVenator |
D |
Jan. 2, 2020, 10:43 p.m. |
OK |
GNU C11 |
TESTS |
77 |
46 |
0 |
|
2300 |
67542271 |
rainboy |
D |
Dec. 24, 2019, 3:32 p.m. |
OK |
GNU C11 |
TESTS |
77 |
265 |
0 |
|
2300 |
67560855 |
_oscar_S21 |
D |
Dec. 24, 2019, 5:32 p.m. |
OK |
GNU C++11 |
TESTS |
77 |
30 |
0 |
|
2300 |
67948910 |
poorpool |
D |
Dec. 30, 2019, 6:46 a.m. |
OK |
GNU C++11 |
TESTS |
77 |
30 |
0 |
|
2300 |
68573340 |
vjudge5 |
D |
Jan. 11, 2020, 3:40 a.m. |
OK |
GNU C++11 |
TESTS |
77 |
31 |
0 |
|
2300 |
68459196 |
spartan01 |
D |
Jan. 9, 2020, 5:27 p.m. |
OK |
GNU C++11 |
TESTS |
77 |
31 |
0 |
|
2300 |
68447534 |
Angle_Kanade |
D |
Jan. 9, 2020, 1:14 p.m. |
OK |
GNU C++11 |
TESTS |
77 |
31 |
0 |
|
2300 |
68410015 |
we_can_2 |
D |
Jan. 8, 2020, 4:37 p.m. |
OK |
GNU C++11 |
TESTS |
77 |
31 |
0 |
|
2300 |
68387868 |
AC__hunter |
D |
Jan. 8, 2020, 7 a.m. |
OK |
GNU C++11 |
TESTS |
77 |
31 |
0 |
|
2300 |
69047934 |
Jevrii |
D |
Jan. 18, 2020, 11:40 a.m. |
OK |
GNU C++11 |
TESTS |
77 |
31 |
0 |
|
2300 |
68940086 |
smilestruggler |
D |
Jan. 16, 2020, 2:08 p.m. |
OK |
GNU C++11 |
TESTS |
77 |
31 |
0 |
|
2300 |
68628013 |
birka0 |
D |
Jan. 12, 2020, 12:18 a.m. |
OK |
GNU C++11 |
TESTS |
77 |
31 |
0 |
|
2300 |
69398719 |
BlueDiamond |
D |
Jan. 23, 2020, 7:31 a.m. |
OK |
GNU C++14 |
TESTS |
77 |
31 |
0 |
|
2300 |
69017875 |
custard_apple |
D |
Jan. 18, 2020, 5:46 a.m. |
OK |
GNU C++14 |
TESTS |
77 |
31 |
0 |
|
2300 |
68945715 |
bhaag_milkha |
D |
Jan. 16, 2020, 4:04 p.m. |
OK |
GNU C++14 |
TESTS |
77 |
31 |
0 |
|
2300 |
68673833 |
sawhil |
D |
Jan. 12, 2020, 5:46 p.m. |
OK |
GNU C++14 |
TESTS |
77 |
31 |
0 |
|
2300 |
68630671 |
bl964131617 |
D |
Jan. 12, 2020, 2:35 a.m. |
OK |
GNU C++14 |
TESTS |
77 |
31 |
0 |
|
2300 |
68497268 |
robxln |
D |
Jan. 10, 2020, 2 p.m. |
OK |
GNU C++14 |
TESTS |
77 |
31 |
0 |
|
2300 |
69288496 |
dtc03012 |
D |
Jan. 22, 2020, 9:13 a.m. |
OK |
GNU C++14 |
TESTS |
77 |
31 |
0 |
|
2300 |
69532697 |
mqt2019 |
D |
Jan. 25, 2020, 5:41 p.m. |
OK |
GNU C++14 |
TESTS |
77 |
31 |
0 |
|
2300 |
69453454 |
wotefa |
D |
Jan. 24, 2020, 7:23 a.m. |
OK |
GNU C++14 |
TESTS |
77 |
31 |
0 |
|
2300 |
69425357 |
ajinkya1p3 |
D |
Jan. 23, 2020, 3:38 p.m. |
OK |
GNU C++14 |
TESTS |
77 |
31 |
0 |
|
2300 |
67671012 |
MicGor |
D |
Dec. 26, 2019, 8:26 p.m. |
OK |
GNU C++17 |
TESTS |
77 |
30 |
0 |
|
2300 |
69046015 |
vannamsc |
D |
Jan. 18, 2020, 11:04 a.m. |
OK |
GNU C++17 |
TESTS |
77 |
31 |
0 |
|
2300 |
69563825 |
GeorgeTorianik |
D |
Jan. 26, 2020, 11:39 a.m. |
OK |
GNU C++17 |
TESTS |
77 |
31 |
0 |
|
2300 |
69268310 |
quailty |
D |
Jan. 21, 2020, 7:33 p.m. |
OK |
GNU C++17 |
TESTS |
77 |
31 |
0 |
|
2300 |
69259879 |
pratikgk45 |
D |
Jan. 21, 2020, 4:44 p.m. |
OK |
GNU C++17 |
TESTS |
77 |
31 |
0 |
|
2300 |
69233789 |
Arayi |
D |
Jan. 21, 2020, 10:30 a.m. |
OK |
GNU C++17 |
TESTS |
77 |
31 |
0 |
|
2300 |
69227687 |
AKone123456 |
D |
Jan. 21, 2020, 8:03 a.m. |
OK |
GNU C++17 |
TESTS |
77 |
31 |
0 |
|
2300 |
69084829 |
oskarfiuk1 |
D |
Jan. 19, 2020, 7:54 a.m. |
OK |
GNU C++17 |
TESTS |
77 |
31 |
0 |
|
2300 |
68943760 |
johutha |
D |
Jan. 16, 2020, 3:20 p.m. |
OK |
GNU C++17 |
TESTS |
77 |
31 |
0 |
|
2300 |
68886934 |
Vanster |
D |
Jan. 15, 2020, 10:18 p.m. |
OK |
GNU C++17 |
TESTS |
77 |
31 |
0 |
|
2300 |
67551722 |
caidodo0_0 |
D |
Dec. 24, 2019, 4:14 p.m. |
OK |
Go |
TESTS |
77 |
61 |
0 |
|
2300 |
67579435 |
bleh0.5 |
D |
Dec. 25, 2019, 5:08 a.m. |
OK |
Java 11 |
TESTS |
77 |
217 |
0 |
|
2300 |
67877326 |
machhra |
D |
Dec. 29, 2019, 1:49 p.m. |
OK |
Java 11 |
TESTS |
77 |
218 |
0 |
|
2300 |
67554714 |
Dukkha |
D |
Dec. 24, 2019, 4:27 p.m. |
OK |
Java 11 |
TESTS |
77 |
248 |
0 |
|
2300 |
67560723 |
lightseba |
D |
Dec. 24, 2019, 5:29 p.m. |
OK |
Java 11 |
TESTS |
77 |
249 |
0 |
|
2300 |
67621329 |
liebert |
D |
Dec. 25, 2019, 6:56 p.m. |
OK |
Java 11 |
TESTS |
77 |
358 |
1228800 |
|
2300 |
67577231 |
sb233 |
D |
Dec. 25, 2019, 3:30 a.m. |
OK |
Java 11 |
TESTS |
77 |
592 |
0 |
|
2300 |
67595757 |
beroul |
D |
Dec. 25, 2019, 10:34 a.m. |
OK |
Java 8 |
TESTS |
77 |
124 |
0 |
|
2300 |
67574141 |
fetetriste |
D |
Dec. 24, 2019, 11:46 p.m. |
OK |
Java 8 |
TESTS |
77 |
124 |
0 |
|
2300 |
67563344 |
KharYusuf |
D |
Dec. 24, 2019, 6:18 p.m. |
OK |
Java 8 |
TESTS |
77 |
124 |
0 |
|
2300 |
67595878 |
beroul |
D |
Dec. 25, 2019, 10:37 a.m. |
OK |
Java 8 |
TESTS |
77 |
139 |
0 |
|
2300 |
68077707 |
luchy0120 |
D |
Jan. 2, 2020, 1:13 p.m. |
OK |
Java 8 |
TESTS |
77 |
139 |
0 |
|
2300 |
67622810 |
catforce |
D |
Dec. 25, 2019, 7:42 p.m. |
OK |
Java 8 |
TESTS |
77 |
139 |
0 |
|
2300 |
67618425 |
TheSawan |
D |
Dec. 25, 2019, 5:43 p.m. |
OK |
Java 8 |
TESTS |
77 |
139 |
0 |
|
2300 |
67568373 |
AnandOza |
D |
Dec. 24, 2019, 8:28 p.m. |
OK |
Java 8 |
TESTS |
77 |
139 |
0 |
|
2300 |
67566901 |
ln_nl |
D |
Dec. 24, 2019, 7:45 p.m. |
OK |
Java 8 |
TESTS |
77 |
139 |
0 |
|
2300 |
69491362 |
unicorn20141 |
D |
Jan. 24, 2020, 10:57 p.m. |
OK |
Java 8 |
TESTS |
77 |
140 |
0 |
|
2300 |
68972496 |
Spheniscine |
D |
Jan. 17, 2020, 7:33 a.m. |
OK |
Kotlin |
TESTS |
77 |
155 |
0 |
|
2300 |
67559005 |
old_boo |
D |
Dec. 24, 2019, 5:07 p.m. |
OK |
Kotlin |
TESTS |
77 |
186 |
716800 |
|
2300 |
68100317 |
SpinDOS |
D |
Jan. 3, 2020, 2:11 a.m. |
OK |
Mono C# |
TESTS |
77 |
62 |
307200 |
|
2300 |
68100264 |
SpinDOS |
D |
Jan. 3, 2020, 2:07 a.m. |
OK |
Mono C# |
TESTS |
77 |
77 |
307200 |
|
2300 |
67558471 |
camypaper |
D |
Dec. 24, 2019, 5:02 p.m. |
OK |
Mono C# |
TESTS |
77 |
77 |
4096000 |
|
2300 |
68450938 |
keymoon |
D |
Jan. 9, 2020, 2:19 p.m. |
OK |
Mono C# |
TESTS |
77 |
93 |
5734400 |
|
2300 |
67560364 |
dcclyde |
D |
Dec. 24, 2019, 5:24 p.m. |
OK |
MS C++ 2017 |
TESTS |
77 |
31 |
0 |
|
2300 |
67564552 |
P___ |
D |
Dec. 24, 2019, 6:44 p.m. |
OK |
MS C++ 2017 |
TESTS |
77 |
31 |
0 |
|
2300 |
67569022 |
extremum |
D |
Dec. 24, 2019, 8:47 p.m. |
OK |
MS C++ 2017 |
TESTS |
77 |
31 |
307200 |
|
2300 |
67601357 |
kurs |
D |
Dec. 25, 2019, 12:03 p.m. |
OK |
MS C++ 2017 |
TESTS |
77 |
31 |
307200 |
|
2300 |
67652149 |
ZA139 |
D |
Dec. 26, 2019, 12:32 p.m. |
OK |
MS C++ 2017 |
TESTS |
77 |
31 |
307200 |
|
2300 |
67607862 |
beemax |
D |
Dec. 25, 2019, 2:15 p.m. |
OK |
MS C++ 2017 |
TESTS |
77 |
46 |
0 |
|
2300 |
67633421 |
Dmitrenko |
D |
Dec. 26, 2019, 5:32 a.m. |
OK |
MS C++ 2017 |
TESTS |
77 |
46 |
307200 |
|
2300 |
68059638 |
AlexanderL |
D |
Jan. 2, 2020, 2:12 a.m. |
OK |
MS C++ 2017 |
TESTS |
77 |
46 |
307200 |
|
2300 |
68058682 |
AlexanderL |
D |
Jan. 2, 2020, 12:53 a.m. |
OK |
MS C++ 2017 |
TESTS |
77 |
46 |
307200 |
|
2300 |
67575915 |
Timonnable |
D |
Dec. 25, 2019, 2:10 a.m. |
OK |
MS C++ 2017 |
TESTS |
77 |
46 |
409600 |
|
2300 |
67963885 |
vjudge2 |
D |
Dec. 30, 2019, 12:37 p.m. |
OK |
PyPy 2 |
TESTS |
77 |
140 |
0 |
|
2300 |
67958944 |
vjudge4 |
D |
Dec. 30, 2019, 10:47 a.m. |
OK |
PyPy 2 |
TESTS |
77 |
140 |
0 |
|
2300 |
67958827 |
vjudge5 |
D |
Dec. 30, 2019, 10:45 a.m. |
OK |
PyPy 2 |
TESTS |
77 |
155 |
0 |
|
2300 |
67561353 |
bcollet |
D |
Dec. 24, 2019, 5:40 p.m. |
OK |
PyPy 2 |
TESTS |
77 |
186 |
0 |
|
2300 |
67549380 |
akifpatel |
D |
Dec. 24, 2019, 4:03 p.m. |
OK |
PyPy 2 |
TESTS |
77 |
186 |
0 |
|
2300 |
67959004 |
MVP |
D |
Dec. 30, 2019, 10:49 a.m. |
OK |
PyPy 2 |
TESTS |
77 |
187 |
0 |
|
2300 |
67586585 |
aaa_bbb_ccc |
D |
Dec. 25, 2019, 8:32 a.m. |
OK |
PyPy 2 |
TESTS |
77 |
202 |
0 |
|
2300 |
67609194 |
shehebe |
D |
Dec. 25, 2019, 2:42 p.m. |
OK |
PyPy 2 |
TESTS |
77 |
233 |
1228800 |
|
2300 |
67563012 |
ashish_arora |
D |
Dec. 24, 2019, 6:11 p.m. |
OK |
PyPy 3 |
TESTS |
77 |
156 |
0 |
|
2300 |
68058485 |
addammy |
D |
Jan. 2, 2020, 12:35 a.m. |
OK |
PyPy 3 |
TESTS |
77 |
186 |
0 |
|
2300 |
67571939 |
malylesio |
D |
Dec. 24, 2019, 10:32 p.m. |
OK |
PyPy 3 |
TESTS |
77 |
187 |
1331200 |
|
2300 |
67698870 |
malylesio |
D |
Dec. 27, 2019, 1:49 p.m. |
OK |
PyPy 3 |
TESTS |
77 |
187 |
1433600 |
|
2300 |
68948708 |
smart_hard |
D |
Jan. 16, 2020, 5:08 p.m. |
OK |
PyPy 3 |
TESTS |
77 |
202 |
0 |
|
2300 |
67622550 |
NoDesire |
D |
Dec. 25, 2019, 7:33 p.m. |
OK |
PyPy 3 |
TESTS |
77 |
202 |
0 |
|
2300 |
67576429 |
Kevin_Tang |
D |
Dec. 25, 2019, 2:45 a.m. |
OK |
PyPy 3 |
TESTS |
77 |
202 |
0 |
|
2300 |
67559900 |
titia |
D |
Dec. 24, 2019, 5:18 p.m. |
OK |
PyPy 3 |
TESTS |
77 |
202 |
0 |
|
2300 |
67552514 |
hyhtsdy |
D |
Dec. 24, 2019, 4:18 p.m. |
OK |
PyPy 3 |
TESTS |
77 |
202 |
0 |
|
2300 |
67567949 |
FireBird23 |
D |
Dec. 24, 2019, 8:16 p.m. |
OK |
PyPy 3 |
TESTS |
77 |
202 |
409600 |
|
2300 |
67551363 |
nwi |
D |
Dec. 24, 2019, 4:12 p.m. |
OK |
Python 2 |
TESTS |
77 |
217 |
0 |
|
2300 |
67558820 |
Sevlll |
D |
Dec. 24, 2019, 5:05 p.m. |
OK |
Python 3 |
TESTS |
77 |
124 |
307200 |
|
2300 |
67582879 |
dlwocks31 |
D |
Dec. 25, 2019, 6:58 a.m. |
OK |
Python 3 |
TESTS |
77 |
124 |
512000 |
|
2300 |
67582325 |
dlwocks31 |
D |
Dec. 25, 2019, 6:43 a.m. |
OK |
Python 3 |
TESTS |
77 |
124 |
512000 |
|
2300 |
67560852 |
robin646087 |
D |
Dec. 24, 2019, 5:32 p.m. |
OK |
Python 3 |
TESTS |
77 |
139 |
307200 |
|
2300 |
67566893 |
r57shell |
D |
Dec. 24, 2019, 7:45 p.m. |
OK |
Python 3 |
TESTS |
77 |
140 |
307200 |
|
2300 |
67564300 |
__ACoder |
D |
Dec. 24, 2019, 6:38 p.m. |
OK |
Python 3 |
TESTS |
77 |
140 |
307200 |
|
2300 |
67551155 |
nexus.chebykin |
D |
Dec. 24, 2019, 4:11 p.m. |
OK |
Python 3 |
TESTS |
77 |
140 |
307200 |
|
2300 |
67547697 |
hiphip |
D |
Dec. 24, 2019, 3:56 p.m. |
OK |
Python 3 |
TESTS |
77 |
140 |
307200 |
|
2300 |
68999419 |
sansen |
D |
Jan. 17, 2020, 6:51 p.m. |
OK |
Rust |
TESTS |
77 |
46 |
0 |
|
2300 |
remove filters
Back to search problems