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 |
472
|
Codeforces Round 270 |
FINISHED |
False |
9000 |
325693504 |
Sept. 28, 2014, 3:35 p.m. |
Problems
B'There is a simple way to create hard tasks: take one simple problem as the query, and try to find an algorithm that can solve it faster than bruteforce. This kind of tasks usually appears in OI contest, and usually involves data structures. Let 's try to create a task, for example, we take the "Hamming distance problem": for two binary strings s and t with the same length, the Hamming distance between them is the number of positions at which the corresponding symbols are different. For example, the Hamming distance between "00111" and "10101" is 2 (the different symbols are marked with bold). We use the Hamming distance problem as a query in the following way: you are given two strings a and b and several queries. Each query will be: what is the Hamming distance between two strings ap1ap1 xe2 x80 x89+ xe2 x80 x891...ap1 xe2 x80 x89+ xe2 x80 x89len xe2 x80 x89- xe2 x80 x891 and bp2bp2 xe2 x80 x89+ xe2 x80 x891...bp2 xe2 x80 x89+ xe2 x80 x89len xe2 x80 x89- xe2 x80 x891? Note, that in this problem the strings are zero-based, that is s xe2 x80 x89= xe2 x80 x89s0s1... s|s| xe2 x80 x89- xe2 x80 x891. The first line contains a string a (1 xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89|a| xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89200000). The second line contains a string b (1 xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89|b| xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89200000). Each character of both strings is either "0" or "1". The third line contains an integer q (1 xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89q xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89400000) -- the number of queries. Each of the following q lines contains three integers: p1, p2 and len (0 xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89p1 xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89|a| xe2 x80 x89- xe2 x80 x89len; 0 xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89p2 xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89|b| xe2 x80 x89- xe2 x80 x89len), these numbers denote the parameters of the current query. Output q integers -- the answers for the queries.'... |
Tutorials
Submissions
Submission Id |
Author(s) |
Index |
Submitted |
Verdict |
Language |
Test Set |
Tests Passed |
Time taken (ms) |
Memory Consumed (bytes) |
Tags |
Rating |
17507796 |
Ferris |
G |
April 25, 2016, 11:33 a.m. |
OK |
GNU C |
TESTS |
23 |
3634 |
3993600 |
|
2800 |
40987847 |
ReaLNero1 |
G |
July 30, 2018, 9:32 p.m. |
OK |
GNU C++ |
TESTS |
23 |
1325 |
166604800 |
|
2800 |
37039578 |
vjudge3 |
G |
April 7, 2018, 6:20 a.m. |
OK |
GNU C++ |
TESTS |
23 |
1419 |
170086400 |
|
2800 |
16439647 |
Memory120 |
G |
March 1, 2016, 11:14 a.m. |
OK |
GNU C++ |
TESTS |
23 |
2245 |
1228800 |
|
2800 |
9223765 |
rootial |
G |
Dec. 22, 2014, 1:11 p.m. |
OK |
GNU C++ |
TESTS |
23 |
2401 |
2252800 |
|
2800 |
17246644 |
chimo |
G |
April 9, 2016, 12:23 a.m. |
OK |
GNU C++ |
TESTS |
23 |
2605 |
246988800 |
|
2800 |
34088207 |
goldgenius |
G |
Jan. 11, 2018, 1:05 p.m. |
OK |
GNU C++ |
TESTS |
23 |
3400 |
128307200 |
|
2800 |
18446745 |
HalfSummer11 |
G |
June 14, 2016, 8:39 a.m. |
OK |
GNU C++ |
TESTS |
23 |
3462 |
261939200 |
|
2800 |
24998130 |
xiejun |
G |
Feb. 24, 2017, 11:50 p.m. |
OK |
GNU C++ |
TESTS |
23 |
3478 |
161382400 |
|
2800 |
18160630 |
Amirnasr |
G |
May 30, 2016, 7:01 p.m. |
OK |
GNU C++ |
TESTS |
23 |
3696 |
87142400 |
|
2800 |
25677056 |
bonfire |
G |
March 20, 2017, 9:32 p.m. |
OK |
GNU C++ |
TESTS |
23 |
4227 |
70963200 |
|
2800 |
9223755 |
rootial |
G |
Dec. 22, 2014, 1:10 p.m. |
OK |
GNU C++0x |
TESTS |
23 |
2386 |
2252800 |
|
2800 |
9207046 |
logicmachine |
G |
Dec. 20, 2014, 1:40 p.m. |
OK |
GNU C++0x |
TESTS |
23 |
3166 |
1638400 |
|
2800 |
10541372 |
johnasselta |
G |
April 1, 2015, 12:17 p.m. |
OK |
GNU C++11 |
TESTS |
23 |
1325 |
21401600 |
|
2800 |
20304732 |
Umqra |
G |
Aug. 31, 2016, 1:53 p.m. |
OK |
GNU C++11 |
TESTS |
23 |
1762 |
51814400 |
|
2800 |
20304716 |
Umqra |
G |
Aug. 31, 2016, 1:52 p.m. |
OK |
GNU C++11 |
TESTS |
23 |
1902 |
51814400 |
|
2800 |
20304690 |
Umqra |
G |
Aug. 31, 2016, 1:51 p.m. |
OK |
GNU C++11 |
TESTS |
23 |
1965 |
205721600 |
|
2800 |
10922626 |
__math |
G |
April 28, 2015, 6:34 p.m. |
OK |
GNU C++11 |
TESTS |
23 |
1980 |
6348800 |
|
2800 |
20307522 |
Umqra |
G |
Aug. 31, 2016, 4:25 p.m. |
OK |
GNU C++11 |
TESTS |
23 |
2168 |
205721600 |
|
2800 |
17983241 |
TsunamiNoLetGo |
G |
May 18, 2016, 5:19 p.m. |
OK |
GNU C++11 |
TESTS |
23 |
3119 |
76083200 |
|
2800 |
26786961 |
FizzyDavid |
G |
May 1, 2017, 2:10 p.m. |
OK |
GNU C++11 |
TESTS |
23 |
3166 |
29184000 |
|
2800 |
26786600 |
FizzyDavid |
G |
May 1, 2017, 1:46 p.m. |
OK |
GNU C++11 |
TESTS |
23 |
3276 |
25600000 |
|
2800 |
57818872 |
py_ultron |
G |
July 26, 2019, 9:28 p.m. |
OK |
GNU C++11 |
TESTS |
23 |
3415 |
51609600 |
|
2800 |
46904929 |
Rezwan.Arefin01 |
G |
Dec. 11, 2018, 1:45 p.m. |
OK |
GNU C++14 |
TESTS |
23 |
1606 |
42291200 |
|
2800 |
25944223 |
sgtlaugh |
G |
March 30, 2017, 7:36 a.m. |
OK |
GNU C++14 |
TESTS |
23 |
1700 |
172441600 |
|
2800 |
31436960 |
unused |
G |
Oct. 17, 2017, 2:55 a.m. |
OK |
GNU C++14 |
TESTS |
23 |
1747 |
6041600 |
|
2800 |
41193672 |
ErdemKirez |
G |
Aug. 3, 2018, 9:35 p.m. |
OK |
GNU C++14 |
TESTS |
23 |
1747 |
34508800 |
|
2800 |
41193668 |
ErdemKirez |
G |
Aug. 3, 2018, 9:34 p.m. |
OK |
GNU C++14 |
TESTS |
23 |
1778 |
37683200 |
|
2800 |
25944201 |
sgtlaugh |
G |
March 30, 2017, 7:36 a.m. |
OK |
GNU C++14 |
TESTS |
23 |
1964 |
159948800 |
|
2800 |
46904790 |
Rezwan.Arefin01 |
G |
Dec. 11, 2018, 1:41 p.m. |
OK |
GNU C++14 |
TESTS |
23 |
1965 |
42291200 |
|
2800 |
37034463 |
I_See_You |
G |
April 7, 2018, 1:28 a.m. |
OK |
GNU C++14 |
TESTS |
23 |
2027 |
169881600 |
|
2800 |
37039605 |
I_See_You |
G |
April 7, 2018, 6:21 a.m. |
OK |
GNU C++14 |
TESTS |
23 |
2043 |
169881600 |
|
2800 |
37034601 |
I_See_You |
G |
April 7, 2018, 1:39 a.m. |
OK |
GNU C++14 |
TESTS |
23 |
2043 |
169881600 |
|
2800 |
45056647 |
vjudge4 |
G |
Oct. 29, 2018, 1:01 p.m. |
OK |
GNU C++17 |
TESTS |
23 |
3104 |
179916800 |
|
2800 |
45056752 |
vjudge3 |
G |
Oct. 29, 2018, 1:04 p.m. |
OK |
GNU C++17 |
TESTS |
23 |
3150 |
180019200 |
|
2800 |
57959305 |
RedNextCentury |
G |
July 29, 2019, 8:48 p.m. |
OK |
GNU C++17 |
TESTS |
23 |
3166 |
52940800 |
|
2800 |
45056919 |
vjudge5 |
G |
Oct. 29, 2018, 1:08 p.m. |
OK |
GNU C++17 |
TESTS |
23 |
3182 |
179916800 |
|
2800 |
45056978 |
vjudge5 |
G |
Oct. 29, 2018, 1:09 p.m. |
OK |
GNU C++17 |
TESTS |
23 |
3260 |
179916800 |
|
2800 |
57959155 |
RedNextCentury |
G |
July 29, 2019, 8:41 p.m. |
OK |
GNU C++17 |
TESTS |
23 |
3774 |
93081600 |
|
2800 |
58787172 |
Benq |
G |
Aug. 13, 2019, 11:48 p.m. |
OK |
GNU C++17 |
TESTS |
23 |
4055 |
4300800 |
|
2800 |
49601927 |
Ahmad1 |
G |
Feb. 7, 2019, 5:30 p.m. |
OK |
GNU C++17 |
TESTS |
23 |
4134 |
48640000 |
|
2800 |
58787131 |
Benq |
G |
Aug. 13, 2019, 11:46 p.m. |
OK |
GNU C++17 |
TESTS |
23 |
5084 |
4300800 |
|
2800 |
60659329 |
ruo |
G |
Sept. 16, 2019, 3:19 a.m. |
OK |
GNU C++17 |
TESTS |
23 |
5178 |
4198400 |
|
2800 |
remove filters
Back to search problems