Forethought Future Cup - Elimination Round

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
1146 Forethought Future Cup - Elimination Round FINISHED False 9000 181655687 April 20, 2019, 6:05 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 1114 ) D Frog Jumping PROGRAMMING dfs and similar math number theory 2100

B"A frog is initially at position 0 on the number line. The frog has two positive integers a and b . From a position k , it can either jump to position k+a or k-b . Let f(x) be the number of distinct integers the frog can reach if it never jumps on an integer outside the interval [0, x] . The frog doesn't need to visit all these integers in one trip, that is, an integer is counted if the frog can somehow reach it if it starts from 0 . Given an integer m , find sum_{i=0}^{m} f(i) . That is, find the sum of all f(i) for i from 0 to m . The first line contains three integers m, a, b ( 1 <= q m <= q 10^9, 1 <= q a,b <= q 10^5 ). Print a single integer, the desired sum. In the first example, we must find f(0)+f(1)+ ldots+f(7) . We have f(0) = 1, f(1) = 1, f(2) = 1, f(3) = 1, f(4) = 1, f(5) = 3, f(6) = 3, f(7) = 8 . The sum of these values is 19 . In the second example, we have f(i) = i+1 , so we want to find sum_{i=0}^{10^9} i+1 . In the third example, the frog can't make any jumps in any case. "...

Tutorials

66639

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
53063417 hos.lyric D April 20, 2019, 6:32 p.m. OK D TESTS 74 280 6041600 2100
64306032 luogu_bot3 D Nov. 5, 2019, 11:28 a.m. OK GNU C++11 TESTS 74 31 0 2100
64107563 MrDecomposition D Nov. 2, 2019, 5:17 p.m. OK GNU C++11 TESTS 74 31 0 2100
63643817 luogu_bot5 D Oct. 28, 2019, 8:58 a.m. OK GNU C++11 TESTS 74 31 0 2100
63642456 luogu_bot4 D Oct. 28, 2019, 8:33 a.m. OK GNU C++11 TESTS 74 31 0 2100
59819087 danya090699 D Aug. 31, 2019, 4:34 p.m. OK GNU C++11 TESTS 74 31 0 2100
57866516 lopare D July 27, 2019, 9:25 p.m. OK GNU C++11 TESTS 74 31 0 2100
57710437 py_ultron D July 24, 2019, 11:20 p.m. OK GNU C++11 TESTS 74 31 0 2100
56791976 yyyz904 D July 10, 2019, 10:59 a.m. OK GNU C++11 TESTS 74 31 0 2100
64299178 luogu_bot2 D Nov. 5, 2019, 9:28 a.m. OK GNU C++11 TESTS 74 31 0 2100
64302649 GJC_xj D Nov. 5, 2019, 10:34 a.m. OK GNU C++11 TESTS 74 31 0 2100
53098032 didgogns D April 21, 2019, 2:41 p.m. OK GNU C++14 TESTS 74 30 819200 2100
53102263 onthefloor D April 21, 2019, 5:13 p.m. OK GNU C++14 TESTS 74 30 2355200 2100
54659075 ahshafi D May 26, 2019, 9:49 a.m. OK GNU C++14 TESTS 74 30 3174400 2100
55610365 ReaLNero1 D June 16, 2019, 5:17 a.m. OK GNU C++14 TESTS 74 30 5734400 2100
53071363 Svyat D April 20, 2019, 7:46 p.m. OK GNU C++14 TESTS 74 30 5734400 2100
53083558 Verjok D April 21, 2019, 7:54 a.m. OK GNU C++14 TESTS 74 30 8806400 2100
62406363 SuiT_Up D Oct. 12, 2019, 9:05 a.m. OK GNU C++14 TESTS 74 31 0 2100
55989849 YJU D June 24, 2019, 6:57 a.m. OK GNU C++14 TESTS 74 31 0 2100
53094294 MrDecomposition D April 21, 2019, 12:44 p.m. OK GNU C++14 TESTS 74 31 0 2100
53076678 DmitryGrigorev D April 20, 2019, 10:07 p.m. OK GNU C++14 TESTS 74 31 0 2100
53653936 keyvankhademi D May 2, 2019, 3:20 a.m. OK GNU C++17 TESTS 74 30 409600 2100
53603909 Atlas17 D May 1, 2019, 9:18 a.m. OK GNU C++17 TESTS 74 30 614400 2100
53604004 Ge_Nie D May 1, 2019, 9:21 a.m. OK GNU C++17 TESTS 74 30 614400 2100
53065928 Constantius D April 20, 2019, 6:49 p.m. OK GNU C++17 TESTS 74 30 1843200 2100
53079794 Kmcode D April 21, 2019, 5:40 a.m. OK GNU C++17 TESTS 74 30 3379200 2100
53267119 black_horse2014 D April 25, 2019, 2:55 a.m. OK GNU C++17 TESTS 74 30 4403200 2100
53082405 mbrc D April 21, 2019, 7:20 a.m. OK GNU C++17 TESTS 74 30 7987200 2100
53321688 Jakvrh1 D April 26, 2019, 1:12 p.m. OK GNU C++17 TESTS 74 30 17612800 2100
54282034 SGHD D May 17, 2019, 1:53 p.m. OK GNU C++17 TESTS 74 31 0 2100
64269062 _CaHTeXHuK_ D Nov. 4, 2019, 6:19 p.m. OK GNU C++17 TESTS 74 31 0 2100
53082864 wolfib D April 21, 2019, 7:32 a.m. OK Java 8 TESTS 74 109 0 2100
53107148 brainfxxk D April 21, 2019, 9:06 p.m. OK Java 8 TESTS 74 109 0 2100
53107313 icpc_loser D April 21, 2019, 9:15 p.m. OK Java 8 TESTS 74 109 0 2100
64873929 bluesky111 D Nov. 14, 2019, 9:08 a.m. OK Java 8 TESTS 74 109 819200 2100
54360960 happybelly D May 18, 2019, 8:37 p.m. OK Java 8 TESTS 74 124 0 2100
54010624 happybelly D May 12, 2019, 1:54 a.m. OK Java 8 TESTS 74 124 0 2100
53126610 hack1nt0 D April 22, 2019, 2:22 p.m. OK Java 8 TESTS 74 124 0 2100
53121943 polyakoff D April 22, 2019, 11:48 a.m. OK Java 8 TESTS 74 124 0 2100
53076018 mikkk D April 20, 2019, 9:39 p.m. OK Java 8 TESTS 74 139 3891200 2100
53672892 dalt D May 2, 2019, 2:08 p.m. OK Java 8 TESTS 74 139 4505600 2100
53086036 TrabajoNocturno D April 21, 2019, 8:57 a.m. OK Mono C# TESTS 74 62 74649600 2100
53068439 math957963 D April 20, 2019, 7:12 p.m. OK MS C++ TESTS 74 31 5939200 2100
53173985 fatant D April 23, 2019, 1:43 a.m. OK MS C++ 2017 TESTS 74 31 614400 2100
53073464 sogrub D April 20, 2019, 8:16 p.m. OK MS C++ 2017 TESTS 74 31 2252800 2100
53066515 SendThemToHell D April 20, 2019, 6:54 p.m. OK MS C++ 2017 TESTS 74 46 2662400 2100
53071994 siwei D April 20, 2019, 7:55 p.m. OK MS C++ 2017 TESTS 74 108 6553600 2100
53076274 pedrosorio D April 20, 2019, 9:48 p.m. OK PyPy 2 TESTS 74 124 7680000 2100
53066908 alexwice D April 20, 2019, 6:57 p.m. OK PyPy 2 TESTS 74 280 10137600 2100
53072334 pineriver D April 20, 2019, 8 p.m. OK PyPy 3 TESTS 74 186 1126400 2100
53072964 titia D April 20, 2019, 8:09 p.m. OK PyPy 3 TESTS 74 202 716800 2100
53071764 Kiri8128 D April 20, 2019, 7:51 p.m. OK PyPy 3 TESTS 74 343 14540800 2100
53069787 Nika86 D April 20, 2019, 7:26 p.m. OK Python 2 TESTS 74 280 1331200 2100
53298481 Helli.code D April 25, 2019, 6:54 p.m. OK Python 2 TESTS 74 358 409600 2100
53068018 nwi D April 20, 2019, 7:07 p.m. OK Python 2 TESTS 74 436 5324800 2100
53070544 algmyr D April 20, 2019, 7:35 p.m. OK Python 3 TESTS 74 202 614400 2100
53304856 zhou2003 D April 26, 2019, 1:41 a.m. OK Python 3 TESTS 74 202 2457600 2100
53073772 Dart-Xeyter D April 20, 2019, 8:20 p.m. OK Python 3 TESTS 74 202 10649600 2100
53322131 EncodeTalker D April 26, 2019, 1:25 p.m. OK Python 3 TESTS 74 217 2560000 2100
53067924 whatshisbucket D April 20, 2019, 7:06 p.m. OK Python 3 TESTS 74 233 2969600 2100

remove filters

Back to search problems