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 466959623 June 30, 2011, 3 p.m.

Problems

Solved
Index
Name
Type
Tags
Community Tag
Rating
( 539 ) E Lostborn PROGRAMMING dp math number theory 2600

Igor K. very much likes a multiplayer role playing game WineAge II. Who knows, perhaps, that might be the reason for his poor performance at the university. As any person who plays the game, he is interested in equipping his hero with as good weapon and outfit as possible. One day, as he was reading the game's forum yet again, he discovered a very interesting fact. As it turns out, each weapon in the game is characterised with k different numbers: a1, ..., ak. They are called hit indicators and according to the game developers' plan they are pairwise coprime. The damage that is inflicted during a hit depends not only on the weapon's characteristics, but also on the hero's strength parameter. Thus, if the hero's strength equals n, than the inflicted damage will be calculated as the number of numbers on the segment , that aren't divisible by any hit indicator ai. Recently, having fulfilled another quest, Igor K. found a new Lostborn sword. He wants to know how much damage he will inflict upon his enemies if he uses it. The first line contains two integers: n and k (1 ≤ n ≤ 1013, 1 ≤ k ≤ 100). They are the indicator of Igor K's hero's strength and the number of hit indicators. The next line contains space-separated k integers ai (1 ≤ ai ≤ 1000). They are Lostborn sword's hit indicators. The given k numbers are pairwise coprime. Print the single number -- the damage that will be inflicted by Igor K.'s hero when he uses his new weapon. Please, do not use the %lld specificator to read or write 64-bit integers in C++. It is preferred to use the cin, cout streams or the %I64d specificator.

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
525947 dalex E July 2, 2011, 11:58 a.m. OK Delphi TESTS 100 670 80998400 2600
988473 DimaKrachun E Dec. 27, 2011, 2:50 p.m. OK Delphi TESTS 100 1310 81100800 2600
988467 DimaKrachun E Dec. 27, 2011, 2:49 p.m. OK Delphi TESTS 100 1390 161280000 2600
988582 DimaKrachun E Dec. 27, 2011, 3:55 p.m. OK Delphi TESTS 100 1500 163020800 2600
988443 DimaKrachun E Dec. 27, 2011, 2:36 p.m. OK Delphi TESTS 100 1550 16896000 2600
988511 DimaKrachun E Dec. 27, 2011, 3:11 p.m. OK Delphi TESTS 100 1940 241459200 2600
642015 vlad107 E Aug. 29, 2011, 2:57 p.m. OK FPC TESTS 100 860 82739200 2600
524902 vilcheuski E July 1, 2011, 2:33 p.m. OK FPC TESTS 100 860 82739200 2600
1434581 sillycross E March 28, 2012, 1:29 a.m. OK FPC TESTS 100 890 45465600 2600
1041980 suanrong E Jan. 13, 2012, 1:36 a.m. OK FPC TESTS 100 940 122470400 2600
642017 vlad107 E Aug. 29, 2011, 2:58 p.m. OK FPC TESTS 100 950 164556800 2600
3854218 vilcheuski E June 10, 2013, 1:58 p.m. OK FPC TESTS 100 1000 81817600 2600
527043 giongto35 E July 3, 2011, 12:59 p.m. OK FPC TESTS 100 1030 243916800 2600
642020 vlad107 E Aug. 29, 2011, 2:59 p.m. OK FPC TESTS 100 1200 246272000 2600
3854211 vilcheuski E June 10, 2013, 1:57 p.m. OK FPC TESTS 100 1281 245248000 2600
525621 NGNCMH E July 2, 2011, 5:12 a.m. OK FPC TESTS 100 1300 82739200 2600
524652 I_love_natalia E July 1, 2011, 12:09 p.m. OK GNU C++ TESTS 100 340 28979200 2600
524651 I_love_natalia E July 1, 2011, 12:07 p.m. OK GNU C++ TESTS 100 420 24985600 2600
626171 ChaRiL E Aug. 22, 2011, 4:32 p.m. OK GNU C++ TESTS 100 420 41472000 2600
9800648 TeaPot E Feb. 11, 2015, 4:26 p.m. OK GNU C++ TESTS 100 436 42086400 2600
9800652 TeaPot E Feb. 11, 2015, 4:27 p.m. OK GNU C++ TESTS 100 466 42086400 2600
522533 Shik E June 30, 2011, 5:42 p.m. OK GNU C++ TESTS 100 480 23449600 2600
626180 ChaRiL E Aug. 22, 2011, 4:37 p.m. OK GNU C++ TESTS 100 480 81510400 2600
724998 ftiasch E Sept. 26, 2011, 6:25 a.m. OK GNU C++ TESTS 100 500 26112000 2600
523782 akashin E July 1, 2011, 5:02 a.m. OK GNU C++ TESTS 100 520 21811200 2600
4450192 I_so_sad E Sept. 13, 2013, 3:20 a.m. OK GNU C++ TESTS 100 530 22016000 2600
6653864 FancyCoder E May 19, 2014, 2:19 a.m. OK GNU C++0x TESTS 100 654 45568000 2600
518940 2222 E June 30, 2011, 4:01 p.m. OK GNU C++0x TESTS 100 700 7782400 2600
550290 subscriber E July 18, 2011, 11:45 a.m. OK GNU C++0x TESTS 100 860 82432000 2600
9227397 sdya E Dec. 22, 2014, 7:28 p.m. OK GNU C++0x TESTS 100 1028 88166400 2600
18039704 poikniok E May 23, 2016, 6:17 a.m. OK GNU C++11 TESTS 100 654 82329600 2600
18845354 Viktor_Terziev E July 1, 2016, 7:13 p.m. OK GNU C++11 TESTS 100 686 24883200 2600
39135131 Flash-boy E June 11, 2018, 3:03 a.m. OK GNU C++11 TESTS 100 716 84172800 2600
35552432 ZzZZzzzZZZZZzzzzzzzz E Feb. 21, 2018, 3:34 p.m. OK GNU C++11 TESTS 100 716 140902400 2600
18845351 Viktor_Terziev E July 1, 2016, 7:13 p.m. OK GNU C++11 TESTS 100 748 49664000 2600
19016114 oml1111 E July 10, 2016, 9:19 p.m. OK GNU C++11 TESTS 100 748 241254400 2600
18885567 Y_UME E July 4, 2016, 3:25 p.m. OK GNU C++11 TESTS 100 778 40448000 2600
57904897 lopare E July 28, 2019, 5:13 p.m. OK GNU C++11 TESTS 100 778 82636800 2600
22715623 BishalG E Dec. 5, 2016, 4:23 p.m. OK GNU C++11 TESTS 100 810 80998400 2600
51148214 xielinhan E March 11, 2019, 5:42 a.m. OK GNU C++11 TESTS 100 810 81100800 2600
28686087 SakurakoujiRuna E July 19, 2017, 6:12 a.m. OK GNU C++14 TESTS 100 530 226406400 2600
32149038 -Morass- E Nov. 9, 2017, 1:04 a.m. OK GNU C++14 TESTS 100 654 40857600 2600
51981555 loopy E March 29, 2019, 4:33 p.m. OK GNU C++14 TESTS 100 810 81817600 2600
38901865 Cmise E June 2, 2018, 7:27 p.m. OK GNU C++14 TESTS 100 810 85094400 2600
47235524 Origims E Dec. 18, 2018, 8:16 p.m. OK GNU C++14 TESTS 100 810 97177600 2600
56017256 sorry_im_smurfing E June 24, 2019, 10:28 p.m. OK GNU C++14 TESTS 100 872 82534400 2600
67922898 EVON E Dec. 29, 2019, 4:30 p.m. OK GNU C++14 TESTS 100 872 82636800 2600
50930873 zhouzhendong E March 7, 2019, 1:53 p.m. OK GNU C++14 TESTS 100 872 84172800 2600
35898858 ______u______ E March 3, 2018, 6:27 p.m. OK GNU C++14 TESTS 100 872 84582400 2600
35898793 _____k_____ E March 3, 2018, 6:25 p.m. OK GNU C++14 TESTS 100 872 84582400 2600
40992581 ReaLNero1 E July 31, 2018, 1:25 a.m. OK GNU C++17 TESTS 100 404 29286400 2600
40849729 I_love_natalia E July 27, 2018, 1:56 p.m. OK GNU C++17 TESTS 100 404 29286400 2600
67609005 kefaa2 E Dec. 25, 2019, 2:38 p.m. OK GNU C++17 TESTS 100 404 228147200 2600
50628394 karasek E March 1, 2019, 7:35 a.m. OK GNU C++17 TESTS 100 498 42086400 2600
45586413 vjudge4 E Nov. 12, 2018, 9:06 a.m. OK GNU C++17 TESTS 100 622 84172800 2600
54095476 vjudge3 E May 14, 2019, 12:52 p.m. OK GNU C++17 TESTS 100 686 80998400 2600
63766096 Roundgod E Oct. 30, 2019, 6:16 a.m. OK GNU C++17 TESTS 100 686 84172800 2600
54095471 nimphy E May 14, 2019, 12:52 p.m. OK GNU C++17 TESTS 100 716 80998400 2600
51981597 nahid08 E March 29, 2019, 4:34 p.m. OK GNU C++17 TESTS 100 810 81817600 2600
55657049 AliShahali1382 E June 16, 2019, 5:58 p.m. OK GNU C++17 TESTS 100 810 176332800 2600
524988 winger E July 1, 2011, 3:24 p.m. OK Java 6 TESTS 100 690 96972800 2600
542892 charleschen E July 12, 2011, 7:52 a.m. OK Java 6 TESTS 100 810 59187200 2600
524986 winger E July 1, 2011, 3:23 p.m. OK Java 6 TESTS 100 840 213299200 2600
4874019 alibaba E Oct. 25, 2013, 2:10 a.m. OK Java 6 TESTS 100 872 58982400 2600
4874036 alibaba E Oct. 25, 2013, 2:16 a.m. OK Java 6 TESTS 100 872 59084800 2600
4874032 alibaba E Oct. 25, 2013, 2:15 a.m. OK Java 6 TESTS 100 936 57139200 2600
522203 S.Yesipenko E June 30, 2011, 5:30 p.m. OK Java 6 TESTS 100 970 107212800 2600
587030 xiaowuc1 E Aug. 5, 2011, 7:13 p.m. OK Java 6 TESTS 100 970 176844800 2600
525060 shilov E July 1, 2011, 4:10 p.m. OK Java 6 TESTS 100 1080 131174400 2600
562650 uwi E July 23, 2011, 1:02 p.m. OK Java 6 TESTS 100 1390 95948800 2600
16620340 mkirsche E March 9, 2016, 4:18 p.m. OK Java 7 TESTS 100 1372 79155200 2600
41724361 slickunit4265752 E Aug. 17, 2018, 5:58 p.m. OK Java 8 TESTS 100 1496 78028800 2600
41723856 slickunit4265752 E Aug. 17, 2018, 5:01 p.m. OK Java 8 TESTS 100 1496 78028800 2600
12904689 hama-du E Sept. 9, 2015, 2:24 a.m. OK Java 8 TESTS 100 1714 66150400 2600
12904721 hama-du E Sept. 9, 2015, 2:34 a.m. OK Java 8 TESTS 100 1808 140902400 2600
12904699 hama-du E Sept. 9, 2015, 2:27 a.m. OK Java 8 TESTS 100 1902 166912000 2600
522563 Hadi_Asiaie E June 30, 2011, 5:44 p.m. OK Mono C# TESTS 100 1750 85913600 2600
526715 antonkov E July 3, 2011, 9:59 a.m. OK MS C++ TESTS 100 450 161280000 2600
526714 antonkov E July 3, 2011, 9:58 a.m. OK MS C++ TESTS 100 480 161280000 2600
30207118 Tampere E Sept. 8, 2017, 4:12 p.m. OK MS C++ TESTS 100 498 244633600 2600
30207141 Tampere E Sept. 8, 2017, 4:13 p.m. OK MS C++ TESTS 100 530 162099200 2600
528333 slavik E July 4, 2011, 7:52 p.m. OK MS C++ TESTS 100 560 45875200 2600
30207039 Tampere E Sept. 8, 2017, 4:09 p.m. OK MS C++ TESTS 100 560 244633600 2600
524470 aan93 E July 1, 2011, 10:07 a.m. OK MS C++ TESTS 100 660 49459200 2600
522913 Oleg805 E June 30, 2011, 6:10 p.m. OK MS C++ TESTS 100 660 211763200 2600
530324 littlekfc E July 7, 2011, 5:56 a.m. OK MS C++ TESTS 100 720 49459200 2600
522929 Oleg805 E June 30, 2011, 6:12 p.m. OK MS C++ TESTS 100 750 211763200 2600
14993144 alexey.shchepin E Dec. 24, 2015, 5:38 p.m. OK Ocaml TESTS 100 778 87961600 2600
14993170 alexey.shchepin E Dec. 24, 2015, 5:40 p.m. OK Ocaml TESTS 100 934 67276800 2600
14989607 alexey.shchepin E Dec. 24, 2015, 5:16 p.m. OK Ocaml TESTS 100 1028 107212800 2600
14993160 alexey.shchepin E Dec. 24, 2015, 5:39 p.m. OK Ocaml TESTS 100 1060 76697600 2600
14979091 alexey.shchepin E Dec. 24, 2015, 4:10 p.m. OK Ocaml TESTS 100 1682 107212800 2600
14982306 alexey.shchepin E Dec. 24, 2015, 4:14 p.m. OK Ocaml TESTS 100 1902 107212800 2600

remove filters

Back to search problems