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 |
---|---|---|---|---|---|---|
1366 | Educational Codeforces Round 89 (Rated for Div. 2) | FINISHED | False | 7200 | 145466711 | June 11, 2020, 2:35 p.m. |
Solved$ |
Index |
Name |
Type |
Tags |
Community Tag |
Rating |
---|---|---|---|---|---|---|
( 10822 ) | D | Two Divisors | PROGRAMMING | constructive algorithms math number theory |
B"You are given n integers a_1, a_2, ... , a_n . For each a_i find its two divisors d_1 > 1 and d_2 > 1 such that gcd(d_1 + d_2, a_i) = 1 (where gcd(a, b) is the greatest common divisor of a and b ) or say that there is no such pair. The first line contains single integer n ( 1 <= n <= 5 cdot 10^5 ) -- the size of the array a . The second line contains n integers a_1, a_2, ... , a_n ( 2 <= a_i <= 10^7 ) -- the array a . To speed up the output, print two lines with n integers in each line. The i -th integers in the first and second lines should be corresponding divisors d_1 > 1 and d_2 > 1 such that gcd(d_1 + d_2, a_i) = 1 or -1 and -1 if there is no such pair. If there are multiple answers, print any of them. Let's look at a_7 = 8 . It has 3 divisors greater than 1 : 2 , 4 , 8 . As you can see, the sum of any pair of divisors is divisible by 2 as well as a_7 . There are other valid pairs of d_1 and d_2 for a_{10}=24 , like (3, 4) or (8, 3) . You can print any of them. "... |
Educational Codeforces Round 89 Editorial |
Submission Id |
Author(s) |
Index |
Submitted |
Verdict |
Language |
Test Set |
Tests Passed |
Time taken (ms) |
Memory Consumed (bytes) |
Tags |
Rating |
---|---|---|---|---|---|---|---|---|---|---|---|
83450845 | ruban | D | June 11, 2020, 4:18 p.m. | OK | Delphi | TESTS | 75 | 780 | 148787200 | ||
83511606 | absinthe | D | June 12, 2020, 8:22 a.m. | OK | GNU C++11 | TESTS | 75 | 217 | 50380800 | ||
83501686 | GsjzTle | D | June 12, 2020, 5:57 a.m. | OK | GNU C++11 | TESTS | 75 | 233 | 100966400 | ||
83464565 | njupt_lyy | D | June 11, 2020, 4:54 p.m. | OK | GNU C++11 | TESTS | 75 | 280 | 84172800 | ||
83532458 | clfzs | D | June 12, 2020, 12:59 p.m. | OK | GNU C++11 | TESTS | 75 | 295 | 96153600 | ||
83503955 | froggyzhang | D | June 12, 2020, 6:37 a.m. | OK | GNU C++11 | TESTS | 75 | 343 | 66150400 | ||
83543668 | nkxjlym | D | June 12, 2020, 3:14 p.m. | OK | GNU C++11 | TESTS | 75 | 343 | 84172800 | ||
83489257 | gcfer | D | June 12, 2020, 1:28 a.m. | OK | GNU C++11 | TESTS | 75 | 358 | 84172800 | ||
83502928 | JJLeo | D | June 12, 2020, 6:17 a.m. | OK | GNU C++11 | TESTS | 75 | 389 | 160358400 | ||
83538885 | hunxuewangzi | D | June 12, 2020, 2:19 p.m. | OK | GNU C++11 | TESTS | 75 | 389 | 200192000 | ||
83469688 | qmiamiao | D | June 11, 2020, 5:41 p.m. | OK | GNU C++11 | TESTS | 75 | 390 | 102195200 | ||
83493337 | MarcosK | D | June 12, 2020, 3:18 a.m. | OK | GNU C++14 | TESTS | 75 | 374 | 51814400 | ||
83562393 | KisekiPurin2019 | D | June 12, 2020, 8:32 p.m. | OK | GNU C++14 | TESTS | 75 | 389 | 84172800 | ||
83512891 | Terryjoy | D | June 12, 2020, 8:40 a.m. | OK | GNU C++14 | TESTS | 75 | 405 | 46796800 | ||
83448865 | iceys | D | June 11, 2020, 4:14 p.m. | OK | GNU C++14 | TESTS | 75 | 405 | 94208000 | ||
83507998 | it_aint_me | D | June 12, 2020, 7:31 a.m. | OK | GNU C++14 | TESTS | 75 | 420 | 48332800 | ||
83463915 | Mboker0109 | D | June 11, 2020, 4:50 p.m. | OK | GNU C++14 | TESTS | 75 | 421 | 50585600 | ||
83487132 | tpaaaa | D | June 12, 2020, 12:10 a.m. | OK | GNU C++14 | TESTS | 75 | 421 | 84172800 | ||
83471736 | __Stranger__ | D | June 11, 2020, 6:03 p.m. | OK | GNU C++14 | TESTS | 75 | 421 | 87756800 | ||
83532539 | LiangMu | D | June 12, 2020, 1 p.m. | OK | GNU C++14 | TESTS | 75 | 421 | 114483200 | ||
83570855 | UPCchenbaorui | D | June 13, 2020, 1:54 a.m. | OK | GNU C++14 | TESTS | 75 | 421 | 250470400 | ||
83508449 | jintiandun | D | June 12, 2020, 7:38 a.m. | OK | GNU C++17 | TESTS | 75 | 358 | 50380800 | ||
83573183 | blackapple749 | D | June 13, 2020, 3:09 a.m. | OK | GNU C++17 | TESTS | 75 | 389 | 86425600 | ||
83450746 | mahdi.hasnat | D | June 11, 2020, 4:18 p.m. | OK | GNU C++17 | TESTS | 75 | 390 | 54681600 | ||
83509952 | vikfil | D | June 12, 2020, 7:59 a.m. | OK | GNU C++17 | TESTS | 75 | 404 | 58163200 | ||
83555625 | noobiesAG | D | June 12, 2020, 6:36 p.m. | OK | GNU C++17 | TESTS | 75 | 405 | 50585600 | ||
83474825 | cookiedoth | D | June 11, 2020, 6:42 p.m. | OK | GNU C++17 | TESTS | 75 | 405 | 50688000 | ||
83567544 | maxovic | D | June 12, 2020, 11:14 p.m. | OK | GNU C++17 | TESTS | 75 | 405 | 84480000 | ||
83508815 | linwanqiao | D | June 12, 2020, 7:43 a.m. | OK | GNU C++17 | TESTS | 75 | 405 | 86425600 | ||
83554059 | nantha_manish | D | June 12, 2020, 6:15 p.m. | OK | GNU C++17 | TESTS | 75 | 420 | 48640000 | ||
83451538 | minmise | D | June 11, 2020, 4:19 p.m. | OK | GNU C++17 | TESTS | 75 | 420 | 48640000 | ||
83481580 | Siberian | D | June 11, 2020, 8:46 p.m. | OK | GNU C++17 (64) | TESTS | 75 | 342 | 53452800 | ||
83462583 | timreizin | D | June 11, 2020, 4:43 p.m. | OK | GNU C++17 (64) | TESTS | 75 | 358 | 51507200 | ||
83472067 | Mip182 | D | June 11, 2020, 6:07 p.m. | OK | GNU C++17 (64) | TESTS | 75 | 358 | 87552000 | ||
83445049 | Heltion | D | June 11, 2020, 4:06 p.m. | OK | GNU C++17 (64) | TESTS | 75 | 358 | 200396800 | ||
83570968 | Geothermal | D | June 13, 2020, 1:58 a.m. | OK | GNU C++17 (64) | TESTS | 75 | 373 | 105984000 | ||
83465661 | ValarDohaeris_ | D | June 11, 2020, 5:02 p.m. | OK | GNU C++17 (64) | TESTS | 75 | 374 | 51404800 | ||
83530214 | 19992147 | D | June 12, 2020, 12:31 p.m. | OK | GNU C++17 (64) | TESTS | 75 | 374 | 52633600 | ||
83530091 | meox | D | June 12, 2020, 12:29 p.m. | OK | GNU C++17 (64) | TESTS | 75 | 374 | 52633600 | ||
83536289 | Chgtaxihe | D | June 12, 2020, 1:49 p.m. | OK | GNU C++17 (64) | TESTS | 75 | 374 | 56934400 | ||
83511882 | Redemptioner | D | June 12, 2020, 8:26 a.m. | OK | GNU C++17 (64) | TESTS | 75 | 389 | 52633600 | ||
83556590 | synapse | D | June 12, 2020, 6:50 p.m. | OK | Go | TESTS | 75 | 374 | 96051200 | ||
83557292 | synapse | D | June 12, 2020, 7:01 p.m. | OK | Go | TESTS | 75 | 436 | 96051200 | ||
83557194 | synapse | D | June 12, 2020, 7 p.m. | OK | Go | TESTS | 75 | 436 | 96051200 | ||
83556254 | synapse | D | June 12, 2020, 6:45 p.m. | OK | Go | TESTS | 75 | 467 | 94617600 | ||
83556917 | synapse | D | June 12, 2020, 6:55 p.m. | OK | Go | TESTS | 75 | 529 | 90419200 | ||
83555434 | synapse | D | June 12, 2020, 6:33 p.m. | OK | Go | TESTS | 75 | 530 | 84582400 | ||
83556155 | synapse | D | June 12, 2020, 6:44 p.m. | OK | Go | TESTS | 75 | 530 | 94617600 | ||
83555752 | synapse | D | June 12, 2020, 6:38 p.m. | OK | Go | TESTS | 75 | 561 | 84684800 | ||
83557743 | synapse | D | June 12, 2020, 7:08 p.m. | OK | Go | TESTS | 75 | 717 | 89292800 | ||
83555966 | synapse | D | June 12, 2020, 6:41 p.m. | OK | Go | TESTS | 75 | 733 | 84582400 | ||
83554266 | awesomelemonade | D | June 12, 2020, 6:17 p.m. | OK | Java 11 | TESTS | 75 | 592 | 85913600 | ||
83514063 | Barnot | D | June 12, 2020, 8:57 a.m. | OK | Java 11 | TESTS | 75 | 639 | 47718400 | ||
83530425 | chaparasagar | D | June 12, 2020, 12:34 p.m. | OK | Java 11 | TESTS | 75 | 639 | 82022400 | ||
83559987 | saikaushik333 | D | June 12, 2020, 7:46 p.m. | OK | Java 11 | TESTS | 75 | 639 | 88371200 | ||
83553051 | awesomelemonade | D | June 12, 2020, 6:01 p.m. | OK | Java 11 | TESTS | 75 | 655 | 85913600 | ||
83555724 | rohanxyzg | D | June 12, 2020, 6:38 p.m. | OK | Java 11 | TESTS | 75 | 670 | 83968000 | ||
83555264 | Ahmed_Hosssam | D | June 12, 2020, 6:31 p.m. | OK | Java 11 | TESTS | 75 | 701 | 96665600 | ||
83531260 | jakejase2 | D | June 12, 2020, 12:44 p.m. | OK | Java 11 | TESTS | 75 | 717 | 47308800 | ||
83466881 | Dukkha | D | June 11, 2020, 5:13 p.m. | OK | Java 11 | TESTS | 75 | 717 | 47308800 | ||
83447338 | bobib | D | June 11, 2020, 4:11 p.m. | OK | Java 11 | TESTS | 75 | 717 | 56217600 | ||
83506849 | ragnarok001 | D | June 12, 2020, 7:16 a.m. | OK | Java 8 | TESTS | 75 | 405 | 115302400 | ||
83506251 | ragnarok001 | D | June 12, 2020, 7:08 a.m. | OK | Java 8 | TESTS | 75 | 436 | 99225600 | ||
83535661 | Vaibhav_patel19 | D | June 12, 2020, 1:40 p.m. | OK | Java 8 | TESTS | 75 | 483 | 100352000 | ||
83477264 | anuj560 | D | June 11, 2020, 7:19 p.m. | OK | Java 8 | TESTS | 75 | 530 | 46284800 | ||
83507040 | prem_cse | D | June 12, 2020, 7:19 a.m. | OK | Java 8 | TESTS | 75 | 530 | 96460800 | ||
83506963 | ln_nl | D | June 12, 2020, 7:17 a.m. | OK | Java 8 | TESTS | 75 | 530 | 96460800 | ||
83564435 | sourav2999 | D | June 12, 2020, 9:19 p.m. | OK | Java 8 | TESTS | 75 | 530 | 113459200 | ||
83544602 | freecs | D | June 12, 2020, 3:24 p.m. | OK | Java 8 | TESTS | 75 | 560 | 122060800 | ||
83477706 | IBatJ | D | June 11, 2020, 7:27 p.m. | OK | Java 8 | TESTS | 75 | 561 | 46284800 | ||
83478130 | Khater | D | June 11, 2020, 7:35 p.m. | OK | Java 8 | TESTS | 75 | 592 | 118681600 | ||
83564065 | Hakiobo | D | June 12, 2020, 9:09 p.m. | OK | Kotlin | TESTS | 75 | 514 | 89804800 | ||
83497066 | Spheniscine | D | June 12, 2020, 4:42 a.m. | OK | Kotlin | TESTS | 75 | 545 | 89907200 | ||
83455428 | elizarov | D | June 11, 2020, 4:27 p.m. | OK | Kotlin | TESTS | 75 | 576 | 167116800 | ||
83456555 | yakamoto | D | June 11, 2020, 4:29 p.m. | OK | Kotlin | TESTS | 75 | 904 | 151244800 | ||
83475904 | speshuric | D | June 11, 2020, 6:58 p.m. | OK | Kotlin | TESTS | 75 | 1544 | 21708800 | ||
83470559 | koboshi | D | June 11, 2020, 5:50 p.m. | OK | Kotlin | TESTS | 75 | 1731 | 258457600 | ||
83456678 | mban259 | D | June 11, 2020, 4:29 p.m. | OK | Mono C# | TESTS | 75 | 733 | 108236800 | ||
83519334 | maddenvvs | D | June 12, 2020, 10:10 a.m. | OK | Mono C# | TESTS | 75 | 873 | 104755200 | ||
83523985 | avtoruxadze | D | June 12, 2020, 11:10 a.m. | OK | Mono C# | TESTS | 75 | 1076 | 98406400 | ||
83512022 | Kasumigaoka | D | June 12, 2020, 8:28 a.m. | OK | MS C++ 2017 | TESTS | 75 | 436 | 50380800 | ||
83455347 | Miris | D | June 11, 2020, 4:27 p.m. | OK | MS C++ 2017 | TESTS | 75 | 810 | 15462400 | ||
83500683 | lioshik_ | D | June 12, 2020, 5:42 a.m. | OK | MS C++ 2017 | TESTS | 75 | 857 | 4300800 | ||
83519725 | getN1ght | D | June 12, 2020, 10:15 a.m. | OK | MS C++ 2017 | TESTS | 75 | 1091 | 50073600 | ||
83465523 | SendThemToHell | D | June 11, 2020, 5:01 p.m. | OK | MS C++ 2017 | TESTS | 75 | 1200 | 46080000 | ||
83471311 | reikiriyama | D | June 11, 2020, 5:59 p.m. | OK | MS C++ 2017 | TESTS | 75 | 1388 | 44134400 | ||
83472492 | Yomapeed | D | June 11, 2020, 6:11 p.m. | OK | MS C++ 2017 | TESTS | 75 | 1435 | 92160000 | ||
83531326 | GreedyCoder999 | D | June 12, 2020, 12:44 p.m. | OK | MS C++ 2017 | TESTS | 75 | 1528 | 86220800 | ||
83453331 | ibrahim.el.hajj.02 | D | June 11, 2020, 4:23 p.m. | OK | MS C++ 2017 | TESTS | 75 | 1762 | 207052800 | ||
83477748 | Staticity | D | June 11, 2020, 7:28 p.m. | OK | MS C++ 2017 | TESTS | 75 | 1793 | 92467200 | ||
83554701 | beethoven97 | D | June 12, 2020, 6:23 p.m. | OK | PyPy 2 | TESTS | 75 | 888 | 99020800 | ||
83529373 | mo-hit | D | June 12, 2020, 12:20 p.m. | OK | PyPy 2 | TESTS | 75 | 904 | 108851200 | ||
83525541 | pratikjain226 | D | June 12, 2020, 11:30 a.m. | OK | PyPy 2 | TESTS | 75 | 951 | 124108800 | ||
83525341 | pratikjain226 | D | June 12, 2020, 11:28 a.m. | OK | PyPy 2 | TESTS | 75 | 982 | 126156800 | ||
83525655 | pratikjain226 | D | June 12, 2020, 11:31 a.m. | OK | PyPy 2 | TESTS | 75 | 1060 | 122777600 | ||
83472095 | beethoven97 | D | June 11, 2020, 6:07 p.m. | OK | PyPy 2 | TESTS | 75 | 1076 | 101068800 | ||
83561422 | Ekinak | D | June 12, 2020, 8:13 p.m. | OK | PyPy 2 | TESTS | 75 | 1201 | 120832000 | ||
83479810 | shehebe | D | June 11, 2020, 8:07 p.m. | OK | PyPy 2 | TESTS | 75 | 1357 | 38707200 | ||
83487446 | ycui11 | D | June 12, 2020, 12:22 a.m. | OK | PyPy 2 | TESTS | 75 | 1512 | 184115200 | ||
83504528 | x3mka | D | June 12, 2020, 6:44 a.m. | OK | PyPy 3 | TESTS | 75 | 873 | 110182400 | ||
83514868 | anishde85 | D | June 12, 2020, 9:09 a.m. | OK | PyPy 3 | TESTS | 75 | 888 | 90419200 | ||
83508690 | Arpanjain.g | D | June 12, 2020, 7:41 a.m. | OK | PyPy 3 | TESTS | 75 | 1092 | 131584000 | ||
83541021 | servermonk | D | June 12, 2020, 2:44 p.m. | OK | PyPy 3 | TESTS | 75 | 1201 | 108339200 | ||
83485218 | gintoki_s | D | June 11, 2020, 10:37 p.m. | OK | PyPy 3 | TESTS | 75 | 1247 | 106905600 | ||
83478663 | gintoki_s | D | June 11, 2020, 7:45 p.m. | OK | PyPy 3 | TESTS | 75 | 1263 | 107212800 | ||
83549786 | vk48962713 | D | June 12, 2020, 5:15 p.m. | OK | PyPy 3 | TESTS | 75 | 1263 | 116633600 | ||
83478203 | manhar | D | June 11, 2020, 7:37 p.m. | OK | PyPy 3 | TESTS | 75 | 1263 | 128819200 | ||
83473812 | Bruteforceman | D | June 11, 2020, 6:28 p.m. | OK | PyPy 3 | TESTS | 75 | 1279 | 121753600 | ||
83551213 | ayuzh | D | June 12, 2020, 5:35 p.m. | OK | PyPy 3 | TESTS | 75 | 1294 | 118784000 | ||
83486246 | tonyu0 | D | June 11, 2020, 11:24 p.m. | OK | Rust | TESTS | 75 | 764 | 67276800 | ||
83452948 | yoshrc | D | June 11, 2020, 4:22 p.m. | OK | Rust | TESTS | 75 | 1060 | 18227200 |
Back to search problems