Codeforces Round 587 (Div. 3)

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
1216 Codeforces Round 587 (Div. 3) FINISHED False 7200 168389687 Sept. 21, 2019, 7:05 a.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 1523 ) E2 Numerical Sequence (hard version) PROGRAMMING binary search math 2300

B'The only difference between the easy and the hard versions is the maximum value of k . You are given an infinite sequence of form "112123123412345 ... " which consist of blocks of all consecutive positive integers written one after another. The first block consists of all numbers from 1 to 1 , the second one -- from 1 to 2 , the third one -- from 1 to 3 , ... , the i -th block consists of all numbers from 1 to i . So the first 56 elements of the sequence are "11212312341234512345612345671234567812345678912345678910". Elements of the sequence are numbered from one. For example, the 1 -st element of the sequence is 1 , the 3 -rd element of the sequence is 2 , the 20 -th element of the sequence is 5 , the 38 -th element is 2 , the 56 -th element of the sequence is 0 . Your task is to answer q independent queries. In the i -th query you are given one integer k_i . Calculate the digit at the position k_i of the sequence. The first line of the input contains one integer q ( 1 <= q <= 500 ) -- the number of queries. The i -th of the following q lines contains one integer k_i (1 <= k_i <= 10^{18}) -- the description of the corresponding query. Print q lines. In the i -th line print one digit x_i (0 <= x_i <= 9) -- the answer to the query i , i.e. x_i should be equal to the element at the position k_i of the sequence. Answers on queries from the first example are described in the problem statement. '...

Tutorials

Codeforces Round #587 (Div. 3) Editorial

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
61032022 ruban E2 Sept. 21, 2019, 6:04 p.m. OK Delphi TESTS 55 31 138240000 2300
61055022 YOK E2 Sept. 22, 2019, 7:47 a.m. OK GNU C11 TESTS 55 31 0 2300
68426930 wow_Wonderful E2 Jan. 9, 2020, 4:14 a.m. OK GNU C++11 TESTS 55 31 0 2300
67587185 ChiNhan E2 Dec. 25, 2019, 8:45 a.m. OK GNU C++11 TESTS 55 31 0 2300
67581241 ChiNhan E2 Dec. 25, 2019, 6:11 a.m. OK GNU C++11 TESTS 55 31 0 2300
66279839 medk E2 Dec. 4, 2019, 4:47 p.m. OK GNU C++11 TESTS 55 31 0 2300
66248277 vjudge5 E2 Dec. 3, 2019, 10:21 p.m. OK GNU C++11 TESTS 55 31 0 2300
66228123 mini4141 E2 Dec. 3, 2019, 1:23 p.m. OK GNU C++11 TESTS 55 31 0 2300
66046594 turtureandavid E2 Nov. 30, 2019, 3:21 p.m. OK GNU C++11 TESTS 55 31 0 2300
69585071 vjudge3 E2 Jan. 26, 2020, 7:04 p.m. OK GNU C++11 TESTS 55 31 0 2300
69887080 xyjw E2 Jan. 31, 2020, 8:37 a.m. OK GNU C++11 TESTS 55 31 0 2300
69094280 zjm1999 E2 Jan. 19, 2020, 11:24 a.m. OK GNU C++11 TESTS 55 31 0 2300
61034245 stefdasca E2 Sept. 21, 2019, 6:59 p.m. OK GNU C++14 TESTS 55 15 0 2300
61034172 stefdasca E2 Sept. 21, 2019, 6:57 p.m. OK GNU C++14 TESTS 55 15 12595200 2300
61361407 gamer37 E2 Sept. 27, 2019, 12:16 p.m. OK GNU C++14 TESTS 55 30 0 2300
61208612 jpSwing E2 Sept. 24, 2019, 10:42 a.m. OK GNU C++14 TESTS 55 30 0 2300
61326707 Hsx E2 Sept. 26, 2019, 1:55 p.m. OK GNU C++14 TESTS 55 30 0 2300
62088561 ok505 E2 Oct. 8, 2019, 4:15 a.m. OK GNU C++14 TESTS 55 30 0 2300
61347088 tokitsukaze E2 Sept. 27, 2019, 5:46 a.m. OK GNU C++14 TESTS 55 30 102400 2300
69080372 vjudge1 E2 Jan. 19, 2020, 6:07 a.m. OK GNU C++14 TESTS 55 31 0 2300
69287398 jkchen E2 Jan. 22, 2020, 8:47 a.m. OK GNU C++14 TESTS 55 31 0 2300
69042090 vjudge2 E2 Jan. 18, 2020, 10:17 a.m. OK GNU C++14 TESTS 55 31 0 2300
66301775 sharmajatin741 E2 Dec. 5, 2019, 7:34 a.m. OK GNU C++17 TESTS 55 30 0 2300
61289075 Hassanosama E2 Sept. 25, 2019, 7:43 p.m. OK GNU C++17 TESTS 55 30 0 2300
61071442 Mahmoud_Monem E2 Sept. 22, 2019, 12:55 p.m. OK GNU C++17 TESTS 55 30 0 2300
61070459 limage E2 Sept. 22, 2019, 12:34 p.m. OK GNU C++17 TESTS 55 30 0 2300
62088501 kadom E2 Oct. 8, 2019, 4:12 a.m. OK GNU C++17 TESTS 55 30 0 2300
61020545 van_persie9 E2 Sept. 21, 2019, 2:28 p.m. OK GNU C++17 TESTS 55 30 0 2300
61449270 mikimowski E2 Sept. 29, 2019, 12:47 a.m. OK GNU C++17 TESTS 55 30 0 2300
61043291 HanaYukii E2 Sept. 22, 2019, 2:32 a.m. OK GNU C++17 TESTS 55 30 204800 2300
61304649 Mr.l2018 E2 Sept. 26, 2019, 6:40 a.m. OK GNU C++17 TESTS 55 30 204800 2300
61045515 Guaguapi E2 Sept. 22, 2019, 4:08 a.m. OK GNU C++17 TESTS 55 30 2048000 2300
61388770 jenish9599 E2 Sept. 27, 2019, 8:17 p.m. OK Java 8 TESTS 55 124 0 2300
64441111 dyhu083 E2 Nov. 7, 2019, 4:22 a.m. OK Java 8 TESTS 55 124 0 2300
62611371 Ruins E2 Oct. 15, 2019, 9:54 a.m. OK Java 8 TESTS 55 124 0 2300
62366061 eng_hardik E2 Oct. 11, 2019, 1:52 p.m. OK Java 8 TESTS 55 124 0 2300
61452112 K1K E2 Sept. 29, 2019, 3:50 a.m. OK Java 8 TESTS 55 124 0 2300
61186224 4mda4mda E2 Sept. 23, 2019, 10:55 p.m. OK Java 8 TESTS 55 124 0 2300
61089055 YahiaSherif E2 Sept. 22, 2019, 8 p.m. OK Java 8 TESTS 55 124 0 2300
61077631 chojh1222 E2 Sept. 22, 2019, 3:07 p.m. OK Java 8 TESTS 55 124 0 2300
61057955 i_will_be_less_than_blue E2 Sept. 22, 2019, 8:38 a.m. OK Java 8 TESTS 55 124 0 2300
61022090 Java E2 Sept. 21, 2019, 2:53 p.m. OK Java 8 TESTS 55 124 0 2300
61075199 Spheniscine E2 Sept. 22, 2019, 2:10 p.m. OK Kotlin TESTS 55 140 0 2300
61074944 Spheniscine E2 Sept. 22, 2019, 2:03 p.m. OK Kotlin TESTS 55 140 0 2300
61074326 Spheniscine E2 Sept. 22, 2019, 1:51 p.m. OK Kotlin TESTS 55 140 0 2300
61090861 Vesbat E2 Sept. 22, 2019, 9:19 p.m. OK Kotlin TESTS 55 155 0 2300
61074059 Spheniscine E2 Sept. 22, 2019, 1:45 p.m. OK Kotlin TESTS 55 187 0 2300
63380332 treasuryonly E2 Oct. 25, 2019, 12:17 p.m. OK Mono C# TESTS 55 46 0 2300
61021324 IlyaCk E2 Sept. 21, 2019, 2:40 p.m. OK Mono C# TESTS 55 62 0 2300
62512551 og.kostya E2 Oct. 13, 2019, 1:39 p.m. OK Mono C# TESTS 55 62 102400 2300
65131943 vjudge5 E2 Nov. 16, 2019, 3:57 a.m. OK MS C++ TESTS 55 31 0 2300
66589160 vjudge2 E2 Dec. 10, 2019, 12:21 p.m. OK MS C++ TESTS 55 31 0 2300
61319299 vjudge1 E2 Sept. 26, 2019, 12:04 p.m. OK MS C++ TESTS 55 31 0 2300
61050537 vjudge3 E2 Sept. 22, 2019, 6:20 a.m. OK MS C++ TESTS 55 31 0 2300
62875757 lichenxi E2 Oct. 18, 2019, 3:16 p.m. OK MS C++ TESTS 55 31 3174400 2300
62374944 MrBear E2 Oct. 11, 2019, 4:57 p.m. OK MS C++ TESTS 55 46 0 2300
61487138 Anarxist E2 Sept. 29, 2019, 1:39 p.m. OK MS C++ TESTS 55 46 0 2300
65126928 nauynehc E2 Nov. 16, 2019, 3:05 a.m. OK MS C++ TESTS 55 46 1228800 2300
69232777 vjudge5 E2 Jan. 21, 2020, 10:09 a.m. OK MS C++ TESTS 55 686 0 2300
61108767 GU_GUGU E2 Sept. 23, 2019, 10:24 a.m. OK MS C++ 2017 TESTS 55 31 0 2300
66204870 vjudge3 E2 Dec. 3, 2019, 1:32 a.m. OK MS C++ 2017 TESTS 55 31 0 2300
63721599 vjudge4 E2 Oct. 29, 2019, 11:31 a.m. OK MS C++ 2017 TESTS 55 31 0 2300
61415461 omerb.zeybek E2 Sept. 28, 2019, 10:06 a.m. OK MS C++ 2017 TESTS 55 31 0 2300
61368582 vjudge3 E2 Sept. 27, 2019, 2:16 p.m. OK MS C++ 2017 TESTS 55 31 0 2300
61365045 vjudge2 E2 Sept. 27, 2019, 1:16 p.m. OK MS C++ 2017 TESTS 55 31 0 2300
61539359 CPLNY E2 Sept. 30, 2019, 8:04 a.m. OK MS C++ 2017 TESTS 55 31 1228800 2300
63768541 vjudge1 E2 Oct. 30, 2019, 7:05 a.m. OK MS C++ 2017 TESTS 55 46 0 2300
63850317 Koropok E2 Oct. 30, 2019, 3:31 p.m. OK MS C++ 2017 TESTS 55 46 0 2300
61106039 AleksanderBalobanov E2 Sept. 23, 2019, 9:14 a.m. OK MS C++ 2017 TESTS 55 46 0 2300
61039244 alexwice E2 Sept. 21, 2019, 10:11 p.m. OK PyPy 2 TESTS 55 202 1843200 2300
61007747 ssk497 E2 Sept. 21, 2019, 11:33 a.m. OK PyPy 2 TESTS 55 265 8192000 2300
62357385 titanlolcat E2 Oct. 11, 2019, 11:22 a.m. OK PyPy 2 TESTS 55 436 4300800 2300
61229008 tjake E2 Sept. 24, 2019, 4:02 p.m. OK PyPy 3 TESTS 55 187 2457600 2300
61075151 tourist_plus_kan E2 Sept. 22, 2019, 2:08 p.m. OK PyPy 3 TESTS 55 187 3174400 2300
61065552 MrLolthe1st E2 Sept. 22, 2019, 10:57 a.m. OK PyPy 3 TESTS 55 187 3174400 2300
61234801 smileyface E2 Sept. 24, 2019, 5:41 p.m. OK PyPy 3 TESTS 55 202 3072000 2300
62687540 bit_2 E2 Oct. 16, 2019, 2:29 p.m. OK PyPy 3 TESTS 55 202 4096000 2300
66451850 510030805voidf E2 Dec. 7, 2019, 11:46 a.m. OK PyPy 3 TESTS 55 218 5529600 2300
61840236 vjudge2 E2 Oct. 4, 2019, 9:24 a.m. OK PyPy 3 TESTS 55 233 5017600 2300
61379073 scheduler E2 Sept. 27, 2019, 5 p.m. OK PyPy 3 TESTS 55 234 5017600 2300
61840334 vjudge1 E2 Oct. 4, 2019, 9:25 a.m. OK PyPy 3 TESTS 55 248 3993600 2300
61248331 macleChen E2 Sept. 25, 2019, 7:07 a.m. OK PyPy 3 TESTS 55 264 6860800 2300
61107722 Woo E2 Sept. 23, 2019, 9:57 a.m. OK Python 2 TESTS 55 1465 0 2300
61064504 MrLolthe1st E2 Sept. 22, 2019, 10:35 a.m. OK Python 3 TESTS 55 140 307200 2300
61518438 namanjain2912 E2 Sept. 29, 2019, 6:25 p.m. OK Python 3 TESTS 55 155 307200 2300
61353142 Code_Bear E2 Sept. 27, 2019, 9:17 a.m. OK Python 3 TESTS 55 155 307200 2300
61527854 NocturneBflat E2 Sept. 30, 2019, 12:29 a.m. OK Python 3 TESTS 55 171 307200 2300
61430537 arp106 E2 Sept. 28, 2019, 2:33 p.m. OK Python 3 TESTS 55 202 307200 2300
61431380 arp106 E2 Sept. 28, 2019, 2:50 p.m. OK Python 3 TESTS 55 217 307200 2300
61988211 happypotamus E2 Oct. 6, 2019, 2:15 p.m. OK Python 3 TESTS 55 218 512000 2300
61382790 riskingh E2 Sept. 27, 2019, 6:01 p.m. OK Python 3 TESTS 55 374 307200 2300
61430011 arp106 E2 Sept. 28, 2019, 2:23 p.m. OK Python 3 TESTS 55 514 307200 2300
65229146 Markus696 E2 Nov. 17, 2019, 3:51 a.m. OK Python 3 TESTS 55 685 307200 2300
61293788 ValenKof E2 Sept. 25, 2019, 10:54 p.m. OK Rust TESTS 55 31 0 2300
62356269 lopol E2 Oct. 11, 2019, 11:03 a.m. OK Rust TESTS 55 46 0 2300
61293988 ValenKof E2 Sept. 25, 2019, 11:05 p.m. OK Rust TESTS 55 46 0 2300
60992216 sansen E2 Sept. 21, 2019, 8:34 a.m. OK Rust TESTS 55 46 0 2300

remove filters

Back to search problems