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 |
---|---|---|---|---|---|---|
1843 | Codeforces Round 881 (Div. 3) | FINISHED | False | 8100 | 49994663 | June 20, 2023, 2:35 p.m. |
Solved$ |
Index |
Name |
Type |
Tags |
Community Tag |
Rating |
---|---|---|---|---|---|---|
( 34353 ) | C | Sum in Binary Tree | PROGRAMMING | bitmasks math trees |
B"Vanya really likes math. One day when he was solving another math problem, he came up with an interesting tree. This tree is built as follows. Initially, the tree has only one vertex with the number 1 -- the root of the tree. Then, Vanya adds two children to it, assigning them consecutive numbers -- 2 and 3 , respectively. After that, he will add children to the vertices in increasing order of their numbers, starting from 2 , assigning their children the minimum unused indices. As a result, Vanya will have an infinite tree with the root in the vertex 1 , where each vertex will have exactly two children, and the vertex numbers will be arranged sequentially by layers. Vanya wondered what the sum of the vertex numbers on the path from the vertex with number 1 to the vertex with number n in such a tree is equal to. Since Vanya doesn't like counting, he asked you to help him find this sum. The first line contains a single integer t ( 1 <= t <= 10^4 ) -- the number of test cases. This is followed by t lines -- the description of the test cases. Each line contains one integer n ( 1 <= n <= 10^{16} ) -- the number of vertex for which Vanya wants to count the sum of vertex numbers on the path from the root to that vertex. For each test case, print one integer -- the desired sum. In the first test case of example on the path from the root to the vertex 3 there are two vertices 1 and 3 , their sum equals 4 . In the second test case of example on the path from the root to the vertex with number 10 there are vertices 1 , 2 , 5 , 10 , sum of their numbers equals 1+2+5+10 = 18 . "... |
Codeforces Round #881 (Div. 3) Editorial |
Submission Id |
Author(s) |
Index |
Submitted |
Verdict |
Language |
Test Set |
Tests Passed |
Time taken (ms) |
Memory Consumed (bytes) |
Tags |
Rating |
---|---|---|---|---|---|---|---|---|---|---|---|
210500466 | ladirajagupta2001 | C | June 21, 2023, 3:30 a.m. | OK | Clang++17 Diagnostics | TESTS | 8 | 187 | 102400 | ||
210517996 | openJDK | C | June 21, 2023, 8:01 a.m. | OK | Clang++20 Diagnostics | TESTS | 8 | 155 | 0 | ||
210569577 | LordxShafin | C | June 21, 2023, 4:20 p.m. | OK | GNU C11 | TESTS | 8 | 61 | 0 | ||
210595177 | DKostrykin_10 | C | June 21, 2023, 9:46 p.m. | OK | GNU C11 | TESTS | 8 | 61 | 0 | ||
210555921 | Electro-F | C | June 21, 2023, 2:11 p.m. | OK | GNU C11 | TESTS | 8 | 62 | 0 | ||
210565988 | antu21 | C | June 21, 2023, 3:46 p.m. | OK | GNU C11 | TESTS | 8 | 62 | 0 | ||
210502511 | ehdxbc | C | June 21, 2023, 4:07 a.m. | OK | GNU C11 | TESTS | 8 | 62 | 0 | ||
210586946 | niloychowdhury | C | June 21, 2023, 7:50 p.m. | OK | GNU C11 | TESTS | 8 | 62 | 0 | ||
210576033 | MohaiMinul2002 | C | June 21, 2023, 5:29 p.m. | OK | GNU C11 | TESTS | 8 | 62 | 0 | ||
210520659 | DHRUBA276 | C | June 21, 2023, 8:27 a.m. | OK | GNU C11 | TESTS | 8 | 62 | 0 | ||
210522007 | SHUVO_9 | C | June 21, 2023, 8:39 a.m. | OK | GNU C11 | TESTS | 8 | 62 | 0 | ||
210554021 | lream2 | C | June 21, 2023, 1:53 p.m. | OK | GNU C11 | TESTS | 8 | 62 | 0 | ||
210576626 | harryb17 | C | June 21, 2023, 5:35 p.m. | OK | GNU C++14 | TESTS | 8 | 15 | 0 | ||
210607992 | Mr_White_ | C | June 22, 2023, 2:12 a.m. | OK | GNU C++14 | TESTS | 8 | 15 | 0 | ||
210581712 | pithilahassan5319 | C | June 21, 2023, 6:36 p.m. | OK | GNU C++14 | TESTS | 8 | 15 | 0 | ||
210577270 | Bedoo | C | June 21, 2023, 5:43 p.m. | OK | GNU C++14 | TESTS | 8 | 15 | 0 | ||
210577248 | V_Gosain | C | June 21, 2023, 5:43 p.m. | OK | GNU C++14 | TESTS | 8 | 15 | 0 | ||
210568192 | gamer37 | C | June 21, 2023, 4:07 p.m. | OK | GNU C++14 | TESTS | 8 | 15 | 0 | ||
210565800 | Chen_Jinhui | C | June 21, 2023, 3:44 p.m. | OK | GNU C++14 | TESTS | 8 | 15 | 0 | ||
210557864 | _steelbenze_ | C | June 21, 2023, 2:28 p.m. | OK | GNU C++14 | TESTS | 8 | 15 | 0 | ||
210556976 | phanbaochau0123 | C | June 21, 2023, 2:20 p.m. | OK | GNU C++14 | TESTS | 8 | 15 | 0 | ||
210552453 | Ikila07 | C | June 21, 2023, 1:39 p.m. | OK | GNU C++14 | TESTS | 8 | 15 | 0 | ||
210549909 | ability_66 | C | June 21, 2023, 1:13 p.m. | OK | GNU C++17 | TESTS | 8 | 0 | 7987200 | ||
210605355 | Longqiang | C | June 22, 2023, 1:20 a.m. | OK | GNU C++17 | TESTS | 8 | 15 | 0 | ||
210610230 | Keane1998 | C | June 22, 2023, 2:54 a.m. | OK | GNU C++17 | TESTS | 8 | 15 | 0 | ||
210611713 | dionysios | C | June 22, 2023, 3:22 a.m. | OK | GNU C++17 | TESTS | 8 | 15 | 0 | ||
210611831 | Elsharaky | C | June 22, 2023, 3:25 a.m. | OK | GNU C++17 | TESTS | 8 | 15 | 0 | ||
210605068 | iAmadoldd | C | June 22, 2023, 1:14 a.m. | OK | GNU C++17 | TESTS | 8 | 15 | 0 | ||
210619892 | JobairHasib | C | June 22, 2023, 5:39 a.m. | OK | GNU C++17 | TESTS | 8 | 15 | 0 | ||
210620629 | DukhDardPeedaKasht | C | June 22, 2023, 5:51 a.m. | OK | GNU C++17 | TESTS | 8 | 15 | 0 | ||
210594265 | ant | C | June 21, 2023, 9:31 p.m. | OK | GNU C++17 | TESTS | 8 | 15 | 0 | ||
210613781 | stonecode | C | June 22, 2023, 3:59 a.m. | OK | GNU C++17 | TESTS | 8 | 15 | 0 | ||
210541923 | NadaMansour20 | C | June 21, 2023, 11:58 a.m. | OK | GNU C++17 (64) | TESTS | 8 | 15 | 0 | ||
210538986 | Krzychuo | C | June 21, 2023, 11:29 a.m. | OK | GNU C++17 (64) | TESTS | 8 | 15 | 0 | ||
210607573 | ace055 | C | June 22, 2023, 2:03 a.m. | OK | GNU C++17 (64) | TESTS | 8 | 15 | 0 | ||
210600721 | ahmed.yasser01 | C | June 21, 2023, 11:34 p.m. | OK | GNU C++17 (64) | TESTS | 8 | 15 | 0 | ||
210577773 | DAIIIS | C | June 21, 2023, 5:48 p.m. | OK | GNU C++17 (64) | TESTS | 8 | 15 | 0 | ||
210563485 | monovariant | C | June 21, 2023, 3:22 p.m. | OK | GNU C++17 (64) | TESTS | 8 | 15 | 0 | ||
210561196 | buttowski_1 | C | June 21, 2023, 3 p.m. | OK | GNU C++17 (64) | TESTS | 8 | 15 | 0 | ||
210557104 | Shinigami_Saleh | C | June 21, 2023, 2:21 p.m. | OK | GNU C++17 (64) | TESTS | 8 | 15 | 0 | ||
210546867 | yrtrt | C | June 21, 2023, 12:46 p.m. | OK | GNU C++17 (64) | TESTS | 8 | 15 | 0 | ||
210540481 | 3.1416 | C | June 21, 2023, 11:43 a.m. | OK | GNU C++17 (64) | TESTS | 8 | 15 | 0 | ||
210567215 | I_Remember_Olya_ashmelev | C | June 21, 2023, 3:58 p.m. | OK | GNU C++20 (64) | TESTS | 8 | 0 | 0 | ||
210610562 | cp_boy | C | June 22, 2023, 3 a.m. | OK | GNU C++20 (64) | TESTS | 8 | 0 | 0 | ||
210604444 | MennatAllahWael246 | C | June 22, 2023, 1 a.m. | OK | GNU C++20 (64) | TESTS | 8 | 0 | 0 | ||
210588335 | jlscheerer | C | June 21, 2023, 8:09 p.m. | OK | GNU C++20 (64) | TESTS | 8 | 0 | 0 | ||
210581469 | A801 | C | June 21, 2023, 6:32 p.m. | OK | GNU C++20 (64) | TESTS | 8 | 0 | 0 | ||
210574756 | pastilia | C | June 21, 2023, 5:15 p.m. | OK | GNU C++20 (64) | TESTS | 8 | 0 | 0 | ||
210574203 | 1022_ankita | C | June 21, 2023, 5:08 p.m. | OK | GNU C++20 (64) | TESTS | 8 | 0 | 0 | ||
210572838 | akarsh_77 | C | June 21, 2023, 4:53 p.m. | OK | GNU C++20 (64) | TESTS | 8 | 0 | 0 | ||
210557115 | nik.danilov | C | June 21, 2023, 2:21 p.m. | OK | GNU C++20 (64) | TESTS | 8 | 0 | 0 | ||
210555445 | 1lu3ch4 | C | June 21, 2023, 2:07 p.m. | OK | GNU C++20 (64) | TESTS | 8 | 0 | 0 | ||
210495669 | libaoshan | C | June 21, 2023, 1:52 a.m. | OK | Go | TESTS | 8 | 15 | 409600 | ||
210518442 | RangeyBhakt | C | June 21, 2023, 8:05 a.m. | OK | Haskell | TESTS | 8 | 77 | 0 | ||
210518290 | KrrishBhakt | C | June 21, 2023, 8:04 a.m. | OK | Haskell | TESTS | 8 | 77 | 0 | ||
210584409 | themadknight45 | C | June 21, 2023, 7:14 p.m. | OK | Java 11 | TESTS | 8 | 186 | 0 | ||
210500743 | QianCCC | C | June 21, 2023, 3:36 a.m. | OK | Java 11 | TESTS | 8 | 186 | 0 | ||
210530145 | GuptaJi | C | June 21, 2023, 9:56 a.m. | OK | Java 11 | TESTS | 8 | 187 | 10240000 | ||
210601173 | new2ac | C | June 21, 2023, 11:44 p.m. | OK | Java 11 | TESTS | 8 | 202 | 0 | ||
210499807 | QianCCC | C | June 21, 2023, 3:18 a.m. | OK | Java 11 | TESTS | 8 | 233 | 0 | ||
210526314 | md_shamim_ahmmed | C | June 21, 2023, 9:20 a.m. | OK | Java 11 | TESTS | 8 | 233 | 0 | ||
210520630 | Blueberry_1 | C | June 21, 2023, 8:26 a.m. | OK | Java 11 | TESTS | 8 | 233 | 0 | ||
210524269 | thenikhilkakarla | C | June 21, 2023, 9 a.m. | OK | Java 11 | TESTS | 8 | 249 | 0 | ||
210500924 | TJ_Codes | C | June 21, 2023, 3:39 a.m. | OK | Java 11 | TESTS | 8 | 249 | 0 | ||
210536871 | HelenMraks | C | June 21, 2023, 11:07 a.m. | OK | Java 11 | TESTS | 8 | 295 | 0 | ||
210618390 | cpp10 | C | June 22, 2023, 5:14 a.m. | OK | Java 17 | TESTS | 8 | 155 | 512000 | ||
210535094 | soumit915 | C | June 21, 2023, 10:49 a.m. | OK | Java 17 | TESTS | 8 | 202 | 409600 | ||
210618471 | cpp10 | C | June 22, 2023, 5:15 a.m. | OK | Java 17 | TESTS | 8 | 202 | 614400 | ||
210520090 | vikash_45 | C | June 21, 2023, 8:21 a.m. | OK | Java 17 | TESTS | 8 | 217 | 204800 | ||
210512374 | vanshkambojkh | C | June 21, 2023, 7:01 a.m. | OK | Java 17 | TESTS | 8 | 218 | 102400 | ||
210494026 | atheshwarank21cs | C | June 21, 2023, 1:11 a.m. | OK | Java 17 | TESTS | 8 | 233 | 819200 | ||
210575807 | Carry1234 | C | June 21, 2023, 5:27 p.m. | OK | Java 17 | TESTS | 8 | 249 | 819200 | ||
210522282 | coder_vishnu | C | June 21, 2023, 8:42 a.m. | OK | Java 17 | TESTS | 8 | 249 | 819200 | ||
210549627 | sravani_20 | C | June 21, 2023, 1:11 p.m. | OK | Java 17 | TESTS | 8 | 280 | 0 | ||
210502823 | aakash_7 | C | June 21, 2023, 4:13 a.m. | OK | Java 17 | TESTS | 8 | 280 | 512000 | ||
210607137 | Monkey_de_Luffy | C | June 22, 2023, 1:55 a.m. | OK | Java 8 | TESTS | 8 | 108 | 0 | ||
210578631 | iamdimonis | C | June 21, 2023, 5:58 p.m. | OK | Java 8 | TESTS | 8 | 109 | 0 | ||
210500158 | magic_kid | C | June 21, 2023, 3:24 a.m. | OK | Java 8 | TESTS | 8 | 109 | 0 | ||
210499989 | hardstone | C | June 21, 2023, 3:21 a.m. | OK | Java 8 | TESTS | 8 | 109 | 0 | ||
210555806 | WalterWhite. | C | June 21, 2023, 2:10 p.m. | OK | Java 8 | TESTS | 8 | 124 | 0 | ||
210499532 | xiaoshua | C | June 21, 2023, 3:12 a.m. | OK | Java 8 | TESTS | 8 | 124 | 0 | ||
210497977 | chuquwan9964 | C | June 21, 2023, 2:42 a.m. | OK | Java 8 | TESTS | 8 | 124 | 0 | ||
210497248 | Ahmad_Hoseiny | C | June 21, 2023, 2:27 a.m. | OK | Java 8 | TESTS | 8 | 124 | 0 | ||
210534089 | esmusssein | C | June 21, 2023, 10:38 a.m. | OK | Java 8 | TESTS | 8 | 139 | 38195200 | ||
210504983 | Juhaied_nabid | C | June 21, 2023, 4:53 a.m. | OK | Java 8 | TESTS | 8 | 155 | 0 | ||
210536127 | hartiksalaria | C | June 21, 2023, 11 a.m. | OK | Kotlin 1.6 | TESTS | 8 | 187 | 0 | ||
210541367 | linxiaotian | C | June 21, 2023, 11:53 a.m. | OK | Kotlin 1.6 | TESTS | 8 | 202 | 614400 | ||
210598875 | _Ahmed_Samy | C | June 21, 2023, 10:54 p.m. | OK | Kotlin 1.7 | TESTS | 8 | 389 | 7680000 | ||
210569608 | AlicesRating | C | June 21, 2023, 4:20 p.m. | OK | MS C++ 2017 | TESTS | 8 | 15 | 0 | ||
210608597 | 286d | C | June 22, 2023, 2:23 a.m. | OK | MS C++ 2017 | TESTS | 8 | 61 | 0 | ||
210526272 | At1L | C | June 21, 2023, 9:19 a.m. | OK | MS C++ 2017 | TESTS | 8 | 61 | 0 | ||
210525416 | Ganseblumchen | C | June 21, 2023, 9:11 a.m. | OK | MS C++ 2017 | TESTS | 8 | 62 | 0 | ||
210501814 | viku_76429 | C | June 21, 2023, 3:56 a.m. | OK | MS C++ 2017 | TESTS | 8 | 62 | 0 | ||
210587055 | patulka | C | June 21, 2023, 7:52 p.m. | OK | PyPy 3 | TESTS | 8 | 171 | 5324800 | ||
210518833 | K1o0n | C | June 21, 2023, 8:09 a.m. | OK | PyPy 3 | TESTS | 8 | 265 | 3993600 | ||
210495214 | MHAII | C | June 21, 2023, 1:41 a.m. | OK | PyPy 3 | TESTS | 8 | 280 | 3686400 | ||
210498202 | Rittin_Sehgal | C | June 21, 2023, 2:47 a.m. | OK | PyPy 3 | TESTS | 8 | 280 | 4300800 | ||
210560386 | LCJLY | C | June 21, 2023, 2:52 p.m. | OK | PyPy 3 | TESTS | 8 | 280 | 4505600 | ||
210578623 | Astar288 | C | June 21, 2023, 5:58 p.m. | OK | PyPy 3 | TESTS | 8 | 295 | 4300800 | ||
210617183 | rajeev.prakash2020 | C | June 22, 2023, 4:55 a.m. | OK | PyPy 3 | TESTS | 8 | 296 | 4300800 | ||
210527512 | ram_1728 | C | June 21, 2023, 9:31 a.m. | OK | PyPy 3 | TESTS | 8 | 311 | 4403200 | ||
210534033 | nevermind___ | C | June 21, 2023, 10:37 a.m. | OK | PyPy 3 | TESTS | 8 | 452 | 4505600 | ||
210491013 | titan23 | C | June 20, 2023, 11:40 p.m. | OK | PyPy 3-64 | TESTS | 8 | 62 | 3072000 | ||
210582381 | ijk-1 | C | June 21, 2023, 6:45 p.m. | OK | PyPy 3-64 | TESTS | 8 | 62 | 4915200 | ||
210491033 | titan23 | C | June 20, 2023, 11:41 p.m. | OK | PyPy 3-64 | TESTS | 8 | 77 | 3686400 | ||
210564082 | Youarenotgood | C | June 21, 2023, 3:27 p.m. | OK | PyPy 3-64 | TESTS | 8 | 77 | 4915200 | ||
210556860 | riroan | C | June 21, 2023, 2:19 p.m. | OK | PyPy 3-64 | TESTS | 8 | 77 | 4915200 | ||
210580409 | mathiaswk | C | June 21, 2023, 6:20 p.m. | OK | PyPy 3-64 | TESTS | 8 | 77 | 5734400 | ||
210507240 | cybsbbb | C | June 21, 2023, 5:32 a.m. | OK | PyPy 3-64 | TESTS | 8 | 92 | 5836800 | ||
210506327 | USYDLDH | C | June 21, 2023, 5:17 a.m. | OK | PyPy 3-64 | TESTS | 8 | 93 | 5529600 | ||
210522863 | reijnnn | C | June 21, 2023, 8:47 a.m. | OK | PyPy 3-64 | TESTS | 8 | 93 | 5836800 | ||
210527257 | HaisTous | C | June 21, 2023, 9:29 a.m. | OK | PyPy 3-64 | TESTS | 8 | 93 | 6246400 | ||
210502281 | jalapathisharathchandra | C | June 21, 2023, 4:04 a.m. | OK | Python 3 | TESTS | 8 | 109 | 614400 | ||
210570695 | -BOOGEYMAN- | C | June 21, 2023, 4:31 p.m. | OK | Python 3 | TESTS | 8 | 109 | 1024000 | ||
210539407 | ok-sana-inf | C | June 21, 2023, 11:33 a.m. | OK | Python 3 | TESTS | 8 | 124 | 614400 | ||
210551214 | Duckling69 | C | June 21, 2023, 1:27 p.m. | OK | Python 3 | TESTS | 8 | 139 | 0 | ||
210495450 | ahmedabdelnaser | C | June 21, 2023, 1:47 a.m. | OK | Python 3 | TESTS | 8 | 139 | 0 | ||
210611469 | anudeep__29 | C | June 22, 2023, 3:19 a.m. | OK | Python 3 | TESTS | 8 | 140 | 0 | ||
210611111 | UnreliableSpare | C | June 22, 2023, 3:11 a.m. | OK | Python 3 | TESTS | 8 | 140 | 0 | ||
210551888 | rostoki | C | June 21, 2023, 1:33 p.m. | OK | Python 3 | TESTS | 8 | 140 | 307200 | ||
210545771 | bsktblman | C | June 21, 2023, 12:36 p.m. | OK | Python 3 | TESTS | 8 | 155 | 0 | ||
210517020 | draft_7 | C | June 21, 2023, 7:51 a.m. | OK | Python 3 | TESTS | 8 | 155 | 0 | ||
210539275 | Stan_Marsh Kenny__McCormick Thief_Executive_Officer | C | June 21, 2023, 11:32 a.m. | OK | Rust 2021 | TESTS | 8 | 77 | 0 |
Back to search problems