Codeforces Round 206 (Div. 1)

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
354 Codeforces Round 206 (Div. 1) FINISHED False 7200 356020197 Oct. 13, 2013, 3:30 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 3106 ) C Vasya and Beautiful Arrays PROGRAMMING brute force dp number theory 2000

B"Vasya's got a birthday coming up and his mom decided to give him an array of positive integers a of length n. Vasya thinks that an array's beauty is the greatest common divisor of all its elements. His mom, of course, wants to give him as beautiful an array as possible (with largest possible beauty). Unfortunately, the shop has only one array a left. On the plus side, the seller said that he could decrease some numbers in the array (no more than by k for each number). The seller can obtain array b from array a if the following conditions hold: bi xe2 x80 x89> xe2 x80 x890; xe2 x80 x820 xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89ai xe2 x80 x89- xe2 x80 x89bi xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89k for all 1 xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89i xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89n. Help mom find the maximum possible beauty of the array she will give to Vasya (that seller can obtain). The first line contains two integers n and k (1 xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89n xe2 x80 x89 xe2 x89 xa4 xe2 x80 x893 xc2 xb7105; xe2 x80 x891 xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89k xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89106). The second line contains n integers ai (1 xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89ai xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89106) -- array a. In the single line print a single number -- the maximum possible beauty of the resulting array. In the first sample we can obtain the array: 3 xe2 x80 x826 xe2 x80 x829 xe2 x80 x8212 xe2 x80 x8212 xe2 x80 x8215 In the second sample we can obtain the next array: 7 xe2 x80 x8221 xe2 x80 x8249 xe2 x80 x8214 xe2 x80 x8277"...

Tutorials

Codeforces Round #206 — Editorial

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
4774962 Gassa C Oct. 13, 2013, 4:58 p.m. OK D TESTS 43 140 24166400 2000
5661448 Misha100896 C Jan. 11, 2014, 8:06 p.m. OK Delphi TESTS 43 31 8089600 2000
4787612 ruban C Oct. 15, 2013, 5:55 a.m. OK Delphi TESTS 43 218 72192000 2000
4787554 ruban C Oct. 15, 2013, 5:37 a.m. OK Delphi TESTS 43 218 72192000 2000
4787608 ruban C Oct. 15, 2013, 5:54 a.m. OK Delphi TESTS 43 265 72192000 2000
4779710 waitnote C Oct. 13, 2013, 9:14 p.m. OK FPC TESTS 43 46 1228800 2000
4788389 babameme C Oct. 15, 2013, 9:08 a.m. OK FPC TESTS 43 46 1331200 2000
4798444 gamo C Oct. 15, 2013, 3:44 p.m. OK FPC TESTS 43 46 1331200 2000
4775650 TiChuot97 C Oct. 13, 2013, 5:10 p.m. OK FPC TESTS 43 46 1331200 2000
4838056 pal3 C Oct. 21, 2013, 1:55 p.m. OK FPC TESTS 43 46 3993600 2000
4788113 vietdoan C Oct. 15, 2013, 8:15 a.m. OK FPC TESTS 43 46 8192000 2000
4783027 DMH C Oct. 14, 2013, 10:41 a.m. OK FPC TESTS 43 46 16076800 2000
6419770 imhereonlyforcookies C April 19, 2014, 4:42 p.m. OK FPC TESTS 43 61 16076800 2000
4809807 Nik_Storm_2010 C Oct. 16, 2013, 7:10 p.m. OK FPC TESTS 43 62 4096000 2000
5629968 Wolfik C Jan. 6, 2014, 11:08 p.m. OK FPC TESTS 43 62 16076800 2000
18900726 TsReaper C July 5, 2016, 12:28 p.m. OK GNU C TESTS 43 62 7987200 2000
4772395 ikbal C Oct. 13, 2013, 4:18 p.m. OK GNU C++ TESTS 43 15 4300800 2000
41964488 Scut82 C Aug. 22, 2018, 11:32 a.m. OK GNU C++ TESTS 43 31 1228800 2000
41957300 Scut82 C Aug. 22, 2018, 7:24 a.m. OK GNU C++ TESTS 43 31 1331200 2000
4783410 nineright C Oct. 14, 2013, 11:56 a.m. OK GNU C++ TESTS 43 31 3993600 2000
4773577 amitsaharana C Oct. 13, 2013, 4:35 p.m. OK GNU C++ TESTS 43 31 3993600 2000
39532286 Icyfox C June 23, 2018, 4:56 a.m. OK GNU C++ TESTS 43 31 5324800 2000
4778812 37ae912 C Oct. 13, 2013, 7:05 p.m. OK GNU C++ TESTS 43 31 5427200 2000
30805747 vjudge1 C Sept. 28, 2017, 1:18 p.m. OK GNU C++ TESTS 43 31 7987200 2000
30805737 vjudge3 C Sept. 28, 2017, 1:17 p.m. OK GNU C++ TESTS 43 31 7987200 2000
4939992 FancyCoder C Oct. 31, 2013, 12:29 a.m. OK GNU C++ TESTS 43 31 7987200 2000
4778902 savinov C Oct. 13, 2013, 7:14 p.m. OK GNU C++0x TESTS 43 15 5222400 2000
9208873 Duxar C Dec. 20, 2014, 5:12 p.m. OK GNU C++0x TESTS 43 31 3993600 2000
4779351 1a1a1a C Oct. 13, 2013, 8:13 p.m. OK GNU C++0x TESTS 43 31 3993600 2000
4788480 Xellos C Oct. 15, 2013, 9:27 a.m. OK GNU C++0x TESTS 43 31 5222400 2000
4784773 mruxim C Oct. 14, 2013, 3:05 p.m. OK GNU C++0x TESTS 43 31 17305600 2000
5138756 niklasb C Nov. 18, 2013, 12:38 a.m. OK GNU C++0x TESTS 43 46 1638400 2000
8976900 o948 C Dec. 4, 2014, 5:06 a.m. OK GNU C++0x TESTS 43 46 3993600 2000
4789131 No_stop C Oct. 15, 2013, 11:12 a.m. OK GNU C++0x TESTS 43 46 3993600 2000
4780746 fanzhengchen C Oct. 14, 2013, 3:07 a.m. OK GNU C++0x TESTS 43 46 3993600 2000
4779280 1a1a1a C Oct. 13, 2013, 8:03 p.m. OK GNU C++0x TESTS 43 46 3993600 2000
12560877 UESTC_Sphinx C Aug. 16, 2015, 12:43 p.m. OK GNU C++11 TESTS 43 31 3993600 2000
40989465 ReaLNero1 C July 30, 2018, 10:57 p.m. OK GNU C++11 TESTS 43 31 5222400 2000
17838824 skypoem C May 11, 2016, 4:38 a.m. OK GNU C++11 TESTS 43 31 7475200 2000
18643461 vjudge1 C June 22, 2016, 9 a.m. OK GNU C++11 TESTS 43 31 9216000 2000
28954630 MintGreen C July 28, 2017, 1:11 p.m. OK GNU C++11 TESTS 43 31 18124800 2000
45120419 vjudge5 C Oct. 31, 2018, 3:46 a.m. OK GNU C++11 TESTS 43 31 24473600 2000
61886219 Rainbow_sjy C Oct. 5, 2019, 3:37 a.m. OK GNU C++11 TESTS 43 46 1228800 2000
42689560 Scut82 C Sept. 8, 2018, 10:47 p.m. OK GNU C++11 TESTS 43 46 1228800 2000
25238683 asifruetcse10 C March 5, 2017, 9:25 a.m. OK GNU C++11 TESTS 43 46 3276800 2000
18655062 AcrossTheSky C June 23, 2016, 1:33 a.m. OK GNU C++11 TESTS 43 46 8396800 2000
54800197 Natsuhltk1 C May 29, 2019, 11:35 a.m. OK GNU C++14 TESTS 43 77 3993600 2000
44398362 nitishk24 C Oct. 16, 2018, 11:51 a.m. OK GNU C++14 TESTS 43 77 16076800 2000
62958914 Hassanosama C Oct. 19, 2019, 10:19 p.m. OK GNU C++14 TESTS 43 78 3993600 2000
46312893 H.D.T C Nov. 28, 2018, 2:12 p.m. OK GNU C++14 TESTS 43 78 3993600 2000
45447901 ductuanlhp C Nov. 8, 2018, 2:21 p.m. OK GNU C++14 TESTS 43 78 3993600 2000
44533808 madhur4127 C Oct. 19, 2018, 7:54 a.m. OK GNU C++14 TESTS 43 78 3993600 2000
23735342 0w1 C Jan. 12, 2017, 10:41 a.m. OK GNU C++14 TESTS 43 78 7168000 2000
64124198 z472421519 C Nov. 3, 2019, 3:38 a.m. OK GNU C++14 TESTS 43 78 7987200 2000
53898773 walht C May 9, 2019, 7:51 a.m. OK GNU C++14 TESTS 43 78 7987200 2000
31115289 Lucky_Sanae C Oct. 7, 2017, 12:53 p.m. OK GNU C++14 TESTS 43 78 7987200 2000
57742578 venkatesh_saki C July 25, 2019, 11:55 a.m. OK GNU C++17 TESTS 43 78 3993600 2000
55569736 vjudge4 C June 14, 2019, 5:52 p.m. OK GNU C++17 TESTS 43 78 7987200 2000
57393756 Luo_Tianyi C July 20, 2019, 3:57 p.m. OK GNU C++17 TESTS 43 93 1228800 2000
50771521 jsh1938 C March 4, 2019, 5:14 a.m. OK GNU C++17 TESTS 43 93 1228800 2000
39055176 SoGood C June 8, 2018, 9:17 p.m. OK GNU C++17 TESTS 43 93 1331200 2000
59966258 gsoares C Sept. 3, 2019, 8:41 p.m. OK GNU C++17 TESTS 43 93 3993600 2000
68952170 practiceboy C Jan. 16, 2020, 6:23 p.m. OK GNU C++17 TESTS 43 93 3993600 2000
63648675 Oom C Oct. 28, 2019, 10:41 a.m. OK GNU C++17 TESTS 43 93 3993600 2000
44533618 madhur4127 C Oct. 19, 2018, 7:48 a.m. OK GNU C++17 TESTS 43 93 4300800 2000
56296116 pkgunboat C June 30, 2019, 6:01 a.m. OK GNU C++17 TESTS 43 93 5222400 2000
4822062 autotaker C Oct. 18, 2013, 10:25 p.m. OK Haskell TESTS 43 109 19148800 2000
4781339 hiukim C Oct. 14, 2013, 5:17 a.m. OK Java 6 TESTS 43 124 12697600 2000
4930496 llaki C Oct. 29, 2013, 6:18 p.m. OK Java 6 TESTS 43 187 921600 2000
6658084 vjudge4 C May 19, 2014, 2:35 p.m. OK Java 6 TESTS 43 280 8601600 2000
4871775 mkirsche C Oct. 24, 2013, 9:07 p.m. OK Java 6 TESTS 43 530 102400 2000
4778795 uwi C Oct. 13, 2013, 7:02 p.m. OK Java 7 TESTS 43 78 0 2000
4784241 tanzaku C Oct. 14, 2013, 1:46 p.m. OK Java 7 TESTS 43 109 23961600 2000
5326784 0p9o8i C Dec. 2, 2013, 9:36 a.m. OK Java 7 TESTS 43 124 102400 2000
4903793 i_m_in C Oct. 26, 2013, 12:46 p.m. OK Java 7 TESTS 43 124 8396800 2000
4787728 cvm C Oct. 15, 2013, 6:40 a.m. OK Java 7 TESTS 43 124 22323200 2000
8862903 alibaba C Nov. 26, 2014, 6:06 p.m. OK Java 7 TESTS 43 139 8396800 2000
5634265 miguelmaurizio C Jan. 7, 2014, 7:04 p.m. OK Java 7 TESTS 43 140 8499200 2000
4778408 ffao C Oct. 13, 2013, 6:28 p.m. OK Java 7 TESTS 43 140 15667200 2000
9421443 Aidos C Jan. 13, 2015, 5:28 a.m. OK Java 7 TESTS 43 155 8089600 2000
5326822 0p9o8i C Dec. 2, 2013, 9:46 a.m. OK Java 7 TESTS 43 156 102400 2000
46920333 Ahmad C Dec. 12, 2018, 3:57 a.m. OK Java 8 TESTS 43 124 0 2000
31960459 aminul C Nov. 1, 2017, 6:46 p.m. OK Java 8 TESTS 43 155 0 2000
69549758 sakt_coder C Jan. 26, 2020, 5:49 a.m. OK Java 8 TESTS 43 155 12902400 2000
47320080 I_love_Harpae C Dec. 21, 2018, 7:08 a.m. OK Java 8 TESTS 43 171 0 2000
51614760 hongquanntct C March 21, 2019, noon OK Java 8 TESTS 43 186 23142400 2000
11181929 lydxlx C May 20, 2015, 7:48 p.m. OK Java 8 TESTS 43 187 10752000 2000
15631137 Empress C Jan. 28, 2016, 2:34 p.m. OK Java 8 TESTS 43 187 11673600 2000
69808252 pulkit1411 C Jan. 30, 2020, 3:06 a.m. OK Java 8 TESTS 43 187 15974400 2000
31136103 Omar_Morsi C Oct. 8, 2017, 7:33 a.m. OK Java 8 TESTS 43 187 18227200 2000
32374682 PrakharJain C Nov. 17, 2017, 10:03 a.m. OK Java 8 TESTS 43 187 23244800 2000
51614504 hongquanntct C March 21, 2019, 11:54 a.m. OK Mono C# TESTS 43 124 38809600 2000
24621683 og.kostya C Feb. 13, 2017, 5:53 a.m. OK MS C# TESTS 43 93 16588800 2000
4803050 flash2048 C Oct. 16, 2013, 6:38 a.m. OK MS C# TESTS 43 124 32563200 2000
7816374 azukun C Sept. 17, 2014, 9:36 a.m. OK MS C# TESTS 43 124 35737600 2000
4844707 ACMega _Dante_ 20120354 C Oct. 22, 2013, 2:47 p.m. OK MS C++ TESTS 43 46 1228800 2000
4857405 Frivolous C Oct. 24, 2013, 7:23 a.m. OK MS C++ TESTS 43 62 1228800 2000
4775747 caustique C Oct. 13, 2013, 5:11 p.m. OK MS C++ TESTS 43 62 1228800 2000
4777671 Krainov_Dmitry C Oct. 13, 2013, 5:56 p.m. OK MS C++ TESTS 43 62 2150400 2000
4774108 Giraffy C Oct. 13, 2013, 4:44 p.m. OK MS C++ TESTS 43 62 3891200 2000
4802335 arosusti C Oct. 16, 2013, 4:17 a.m. OK MS C++ TESTS 43 62 3891200 2000
4780588 lost3030 C Oct. 14, 2013, 2:24 a.m. OK MS C++ TESTS 43 62 3993600 2000
4858234 Frivolous C Oct. 24, 2013, 9:46 a.m. OK MS C++ TESTS 43 62 5222400 2000
4804282 serg3232 C Oct. 16, 2013, 9:24 a.m. OK MS C++ TESTS 43 62 7884800 2000
5351786 khayyam C Dec. 5, 2013, 4:55 a.m. OK MS C++ TESTS 43 62 7884800 2000
35857098 ______i______ C March 2, 2018, 8:34 p.m. OK PyPy 3 TESTS 43 358 47718400 2000
35855162 ______M______ C March 2, 2018, 7:56 p.m. OK PyPy 3 TESTS 43 358 47718400 2000
35861552 ______u______ C March 2, 2018, 10:05 p.m. OK PyPy 3 TESTS 43 358 47718400 2000
35861374 ______n______ C March 2, 2018, 10:01 p.m. OK PyPy 3 TESTS 43 358 47718400 2000
35860930 _____i_____ C March 2, 2018, 9:52 p.m. OK PyPy 3 TESTS 43 358 47718400 2000
35860861 _____k_____ C March 2, 2018, 9:50 p.m. OK PyPy 3 TESTS 43 358 47718400 2000
35857687 ______h______ C March 2, 2018, 8:45 p.m. OK PyPy 3 TESTS 43 358 47718400 2000
35857683 ______k______ C March 2, 2018, 8:45 p.m. OK PyPy 3 TESTS 43 358 47718400 2000
23000811 Yash_ C Dec. 15, 2016, 8:30 a.m. OK PyPy 3 TESTS 43 389 31846400 2000
8232294 Sergiu C Oct. 14, 2014, 10:34 p.m. OK Python 2 TESTS 43 311 16076800 2000
5568527 yugle7 C Dec. 30, 2013, 11:32 a.m. OK Python 3 TESTS 43 280 22425600 2000
29818015 lawrence.long C Aug. 27, 2017, 3:01 a.m. OK Python 3 TESTS 43 358 21606400 2000
42135279 Mk_Python_v1 C Aug. 26, 2018, 10:57 p.m. OK Python 3 TESTS 43 389 21504000 2000
26889198 maratonando3 C May 5, 2017, 9:42 p.m. OK Python 3 TESTS 43 732 30515200 2000
26889182 maratonando2 C May 5, 2017, 9:41 p.m. OK Python 3 TESTS 43 748 31846400 2000
26889286 maratonando2 C May 5, 2017, 9:54 p.m. OK Python 3 TESTS 43 764 31744000 2000
4913116 howsiwei C Oct. 27, 2013, 1:05 p.m. OK Ruby TESTS 43 358 13209600 2000
4930328 howsiwei C Oct. 29, 2013, 5:42 p.m. OK Ruby TESTS 43 530 17203200 2000
4913112 howsiwei C Oct. 27, 2013, 1:05 p.m. OK Ruby TESTS 43 530 17203200 2000
5763417 dc. C Jan. 21, 2014, 8:24 a.m. OK Ruby TESTS 43 576 26521600 2000
4927307 c.commoner C Oct. 29, 2013, 8:50 a.m. OK Ruby TESTS 43 577 24883200 2000
4926895 c.commoner C Oct. 29, 2013, 7:15 a.m. OK Ruby TESTS 43 717 25600000 2000

remove filters

Back to search problems