Codeforces Beta Round 76 (Div. 1 Only)

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
93 Codeforces Beta Round 76 (Div. 1 Only) FINISHED False 7200 435164379 June 30, 2011, 3 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 434 ) C Azembler PROGRAMMING brute force implementation 2400

B'After the Search Ultimate program that searched for strings in a text failed, Igor K. got to think: "Why on Earth does my program work so slowly?" As he double-checked his code, he said: "My code contains no errors, yet I know how we will improve Search Ultimate!" and took a large book from the shelves. The book read "Azembler. Principally New Approach". Having carefully thumbed through the book, Igor K. realised that, as it turns out, you can multiply the numbers dozens of times faster. "Search Ultimate will be faster than it has ever been!" -- the fellow shouted happily and set to work. Let us now clarify what Igor 's idea was. The thing is that the code that was generated by a compiler was far from perfect. Standard multiplying does work slower than with the trick the book mentioned. The Azembler language operates with 26 registers (eax, ebx, ..., ezx) and two commands: On the first thought the second operation seems meaningless, but as it turns out, it is acceptable to write the operation as lea ecx, [eax + ebx], lea ecx, [k*eax] or even lea ecx, [ebx + k*eax], where k = 1, 2, 4 or 8. As a result, the register ecx will be equal to the numbers eax + ebx, k*eax and ebx + k*eax correspondingly. However, such operation is fulfilled many times, dozens of times faster that the usual multiplying of numbers. And using several such operations, one can very quickly multiply some number by some other one. Of course, instead of eax, ebx and ecx you are allowed to use any registers. For example, let the eax register contain some number that we should multiply by 41. It takes us 2 lines: lea ebx, [eax + 4*eax] // now ebx = 5*eax lea eax, [eax + 8*ebx] // now eax = eax + 8*ebx = 41*eax Igor K. got interested in the following question: what is the minimum number of lea operations needed to multiply by the given number n and how to do it? Your task is to help him. Consider that at the initial moment of time eax contains a number that Igor K. was about to multiply by '...

Tutorials

Codeforces Beta Round 76 - задача Е div 1 глазами ее автора.

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
543056 calmarj C July 12, 2011, 11:04 a.m. OK Delphi TESTS 255 220 921600 2400
525943 dalex C July 2, 2011, 11:56 a.m. OK Delphi TESTS 255 220 921600 2400
531436 malcolm C July 8, 2011, 8:33 a.m. OK Delphi TESTS 255 3300 921600 2400
526038 NGNCMH C July 2, 2011, 1:05 p.m. OK FPC TESTS 255 170 1024000 2400
641930 vlad107 C Aug. 29, 2011, 1:58 p.m. OK FPC TESTS 255 3050 1024000 2400
523413 Sereja C June 30, 2011, 9:24 p.m. OK FPC TESTS 255 3800 1126400 2400
14193610 130705009 C Nov. 11, 2015, 7:42 a.m. OK GNU C++ TESTS 255 30 0 2400
4874452 zimpha C Oct. 25, 2013, 4:38 a.m. OK GNU C++ TESTS 255 30 0 2400
1116761 vjudge2 C Jan. 25, 2012, 12:31 p.m. OK GNU C++ TESTS 255 30 1331200 2400
542706 fuch C July 12, 2011, 3:32 a.m. OK GNU C++ TESTS 255 30 1331200 2400
523893 tmt514 C July 1, 2011, 6:04 a.m. OK GNU C++ TESTS 255 30 1331200 2400
518945 peter50216 C June 30, 2011, 4:01 p.m. OK GNU C++ TESTS 255 30 1331200 2400
1999932 vepifanov C Aug. 11, 2012, noon OK GNU C++ TESTS 255 30 1433600 2400
1116901 _onp_ C Jan. 25, 2012, 1:15 p.m. OK GNU C++ TESTS 255 30 1433600 2400
530550 Malkovsky C July 7, 2011, 11:46 a.m. OK GNU C++ TESTS 255 30 1433600 2400
530537 Malkovsky C July 7, 2011, 11:35 a.m. OK GNU C++ TESTS 255 30 1433600 2400
3293016 ChuckLin2014 C March 12, 2013, 5:54 a.m. OK GNU C++0x TESTS 255 62 0 2400
9227527 sdya C Dec. 22, 2014, 7:47 p.m. OK GNU C++0x TESTS 255 124 0 2400
520751 2222 C June 30, 2011, 4:34 p.m. OK GNU C++0x TESTS 255 140 3072000 2400
520952 chyx C June 30, 2011, 4:39 p.m. OK GNU C++0x TESTS 255 200 9523200 2400
1126588 Archon.JK C Jan. 30, 2012, 9:06 a.m. OK GNU C++0x TESTS 255 220 1433600 2400
522305 kcm1700 C June 30, 2011, 5:33 p.m. OK GNU C++0x TESTS 255 1420 23961600 2400
528588 ballon C July 5, 2011, 7:19 a.m. OK GNU C++0x TESTS 255 3450 1433600 2400
25487871 YaShem C March 15, 2017, 12:49 a.m. OK GNU C++11 TESTS 255 30 2048000 2400
64568202 zrmpaul C Nov. 9, 2019, 8:17 a.m. OK GNU C++11 TESTS 255 62 0 2400
60348993 luogu_bot3 C Sept. 10, 2019, 1:36 p.m. OK GNU C++11 TESTS 255 62 0 2400
58033888 luogu_bot4 C July 30, 2019, 5:17 p.m. OK GNU C++11 TESTS 255 62 0 2400
57904944 lopare C July 28, 2019, 5:14 p.m. OK GNU C++11 TESTS 255 62 0 2400
56822951 zrmpaul C July 11, 2019, 2:09 a.m. OK GNU C++11 TESTS 255 62 0 2400
56821429 luogu_bot1 C July 11, 2019, 12:47 a.m. OK GNU C++11 TESTS 255 62 0 2400
56781779 luogu_bot5 C July 10, 2019, 6:35 a.m. OK GNU C++11 TESTS 255 62 0 2400
55326757 MagicSpark C June 9, 2019, 8:32 a.m. OK GNU C++11 TESTS 255 62 0 2400
30970786 -skyline- C Oct. 3, 2017, 2:56 p.m. OK GNU C++11 TESTS 255 62 0 2400
29697940 ITer C Aug. 23, 2017, 4:55 a.m. OK GNU C++14 TESTS 255 30 0 2400
27424987 Eson C May 29, 2017, 7:35 a.m. OK GNU C++14 TESTS 255 30 0 2400
23671612 Ali.Pi C Jan. 9, 2017, 9:58 p.m. OK GNU C++14 TESTS 255 30 1945600 2400
56017246 sorry_im_smurfing C June 24, 2019, 10:28 p.m. OK GNU C++14 TESTS 255 62 0 2400
56833558 eddysboy C July 11, 2019, 8:01 a.m. OK GNU C++14 TESTS 255 62 204800 2400
32667849 BackOnTrack C Nov. 26, 2017, 9:46 a.m. OK GNU C++14 TESTS 255 62 1843200 2400
35898856 ______u______ C March 3, 2018, 6:27 p.m. OK GNU C++14 TESTS 255 62 2048000 2400
35898791 _____k_____ C March 3, 2018, 6:25 p.m. OK GNU C++14 TESTS 255 62 2048000 2400
35898463 ______n______ C March 3, 2018, 6:16 p.m. OK GNU C++14 TESTS 255 62 2048000 2400
35897997 _____i_____ C March 3, 2018, 6:11 p.m. OK GNU C++14 TESTS 255 62 2048000 2400
56822146 qinding C July 11, 2019, 1:32 a.m. OK GNU C++17 TESTS 255 62 0 2400
56821426 vjudge1 C July 11, 2019, 12:47 a.m. OK GNU C++17 TESTS 255 62 0 2400
56821425 BlahDuckling747 C July 11, 2019, 12:47 a.m. OK GNU C++17 TESTS 255 62 0 2400
55330792 llbra9z C June 9, 2019, 10:51 a.m. OK GNU C++17 TESTS 255 62 0 2400
40030781 ruo C July 6, 2018, 12:59 p.m. OK GNU C++17 TESTS 255 62 0 2400
56821553 BlahDuckling747 C July 11, 2019, 12:55 a.m. OK GNU C++17 TESTS 255 62 204800 2400
56836530 DerekFeng C July 11, 2019, 9:20 a.m. OK GNU C++17 TESTS 255 92 0 2400
56834953 sjc061031 C July 11, 2019, 8:39 a.m. OK GNU C++17 TESTS 255 92 0 2400
41430991 zhupengfei C Aug. 10, 2018, 12:33 p.m. OK GNU C++17 TESTS 255 92 4608000 2400
56824591 vjudge2 C July 11, 2019, 3:13 a.m. OK GNU C++17 TESTS 255 154 0 2400
611566 tux1986 C Aug. 15, 2011, 2:18 a.m. OK Java 6 TESTS 255 110 34918400 2400
544887 charleschen C July 14, 2011, 4:11 a.m. OK Java 6 TESTS 255 110 34918400 2400
523284 uwi C June 30, 2011, 7:55 p.m. OK Java 6 TESTS 255 140 43110400 2400
542537 ostrovski.alex C July 11, 2011, 7:42 p.m. OK Java 6 TESTS 255 140 43417600 2400
524607 winger C July 1, 2011, 11:45 a.m. OK Java 6 TESTS 255 160 43622400 2400
524411 S.Yesipenko C July 1, 2011, 9:38 a.m. OK Java 6 TESTS 255 200 34918400 2400
518217 Egor C June 30, 2011, 3:49 p.m. OK Java 6 TESTS 255 220 43008000 2400
522230 yiuyuho C June 30, 2011, 5:31 p.m. OK Java 6 TESTS 255 230 43212800 2400
526833 Slamur C July 3, 2011, 11:10 a.m. OK Java 6 TESTS 255 270 43110400 2400
521824 Jokser C June 30, 2011, 4:54 p.m. OK Java 6 TESTS 255 280 43622400 2400
5037991 pitfall C Nov. 9, 2013, 5:33 p.m. OK Java 7 TESTS 255 780 0 2400
520378 dzhulgakov C June 30, 2011, 4:27 p.m. OK MS C++ TESTS 255 30 1433600 2400
521773 poopi C June 30, 2011, 4:53 p.m. OK MS C++ TESTS 255 50 1945600 2400
524657 odorf C July 1, 2011, 12:12 p.m. OK MS C++ TESTS 255 50 43520000 2400
522239 natalia C June 30, 2011, 5:31 p.m. OK MS C++ TESTS 255 90 1433600 2400
12303043 HappyNewYearMike C Aug. 1, 2015, 11:40 a.m. OK MS C++ TESTS 255 122 2355200 2400
525048 Fdg C July 1, 2011, 4:05 p.m. OK MS C++ TESTS 255 130 3788800 2400
1908111 YX201314 C July 18, 2012, 12:43 a.m. OK MS C++ TESTS 255 140 1536000 2400
520675 Gerald C June 30, 2011, 4:33 p.m. OK MS C++ TESTS 255 170 212070400 2400
523228 slavik C June 30, 2011, 7:37 p.m. OK MS C++ TESTS 255 190 19046400 2400
527602 mylyanyk.ivan C July 4, 2011, 7:02 a.m. OK MS C++ TESTS 255 220 6963200 2400

remove filters

Back to search problems