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 |
---|---|---|---|---|---|---|
1044 | Lyft Level 5 Challenge 2018 - Final Round | FINISHED | False | 7200 | 190468199 | Nov. 4, 2018, 6:10 p.m. |
Solved$ |
Index |
Name |
Type |
Tags |
Community Tag |
Rating |
---|---|---|---|---|---|---|
( 1578 ) | B | Intersecting Subtrees | PROGRAMMING | dfs and similar interactive trees | 1900 |
B"You are playing a strange game with Li Chen. You have a tree with n nodes drawn on a piece of paper. All nodes are unlabeled and distinguishable. Each of you independently labeled the vertices from 1 to n . Neither of you know the other's labelling of the tree. You and Li Chen each chose a subtree (i.e., a connected subgraph) in that tree. Your subtree consists of the vertices labeled x_1, x_2, ldots, x_{k_1} in your labeling, Li Chen's subtree consists of the vertices labeled y_1, y_2, ldots, y_{k_2} in his labeling. The values of x_1, x_2, ldots, x_{k_1} and y_1, y_2, ldots, y_{k_2} are known to both of you. You want to determine whether your subtrees have at least one common vertex. Luckily, your friend Andrew knows both labelings of the tree. You can ask Andrew at most 5 questions, each of which is in one of the following two forms: Determine whether the two subtrees have at least one common vertex after asking some questions. If there is at least one common vertex, determine one of your labels for any of the common vertices. Each test consists of several test cases. The first line of input contains a single integer t ( 1 <= q t <= q 100 ) -- the number of test cases. For each testcase, your program should interact in the following format. The first line contains a single integer n ( 1 <= q n <= q 1 ,000 ) -- the number of nodes in the tree. Each of the next n-1 lines contains two integers a_i and b_i ( 1 <= q a_i, b_i <= q n ) -- the edges of the tree, indicating an edge between node a_i and b_i according to your labeling of the nodes. The next line contains a single integer k_1 ( 1 <= q k_1 <= q n ) -- the number of nodes in your subtree. The next line contains k_1 distinct integers x_1,x_2, ldots,x_{k_1} ( 1 <= q x_i <= q n ) -- the indices of the nodes in your subtree, according to your labeling. It is guarante"... |
Lyft Level 5 Challenge 2018 — Final Round — Editorial |
Submission Id |
Author(s) |
Index |
Submitted |
Verdict |
Language |
Test Set |
Tests Passed |
Time taken (ms) |
Memory Consumed (bytes) |
Tags |
Rating |
---|---|---|---|---|---|---|---|---|---|---|---|
47447814 | star_magic_young | B | Dec. 24, 2018, 7:34 a.m. | OK | GNU C++11 | TESTS | 90 | 46 | 0 | 1900 | |
47447774 | star_magic_young | B | Dec. 24, 2018, 7:32 a.m. | OK | GNU C++11 | TESTS | 90 | 62 | 0 | 1900 | |
47004764 | Itst | B | Dec. 14, 2018, 1:25 p.m. | OK | GNU C++11 | TESTS | 90 | 62 | 0 | 1900 | |
47004710 | Itst | B | Dec. 14, 2018, 1:23 p.m. | OK | GNU C++11 | TESTS | 90 | 62 | 0 | 1900 | |
46266479 | Sooke | B | Nov. 27, 2018, 3:30 a.m. | OK | GNU C++11 | TESTS | 90 | 62 | 0 | 1900 | |
46014914 | redbag | B | Nov. 21, 2018, 1:48 a.m. | OK | GNU C++11 | TESTS | 90 | 62 | 102400 | 1900 | |
58957627 | siuyu | B | Aug. 17, 2019, 1:43 p.m. | OK | GNU C++11 | TESTS | 90 | 93 | 204800 | 1900 | |
55114865 | vjudge4 | B | June 5, 2019, 8:11 a.m. | OK | GNU C++11 | TESTS | 90 | 93 | 204800 | 1900 | |
45297606 | YerzhanU | B | Nov. 4, 2018, 7:17 p.m. | OK | GNU C++11 | TESTS | 90 | 93 | 204800 | 1900 | |
45292878 | RomaWhite | B | Nov. 4, 2018, 6:36 p.m. | OK | GNU C++11 | TESTS | 90 | 93 | 307200 | 1900 | |
66824408 | nimom | B | Dec. 14, 2019, 8:28 a.m. | OK | GNU C++14 | TESTS | 90 | 93 | 409600 | 1900 | |
47878627 | GYLin | B | Jan. 3, 2019, 4:57 p.m. | OK | GNU C++14 | TESTS | 90 | 93 | 409600 | 1900 | |
46345933 | Kamyar | B | Nov. 28, 2018, 6:08 p.m. | OK | GNU C++14 | TESTS | 90 | 93 | 409600 | 1900 | |
56962464 | NamSPro | B | July 13, 2019, 7:07 a.m. | OK | GNU C++14 | TESTS | 90 | 108 | 819200 | 1900 | |
56836588 | vjudge2 | B | July 11, 2019, 9:22 a.m. | OK | GNU C++14 | TESTS | 90 | 108 | 819200 | 1900 | |
61958177 | tjd229 | B | Oct. 6, 2019, 6:36 a.m. | OK | GNU C++14 | TESTS | 90 | 109 | 204800 | 1900 | |
62946325 | prerak872 | B | Oct. 19, 2019, 5:29 p.m. | OK | GNU C++14 | TESTS | 90 | 109 | 409600 | 1900 | |
52651958 | bluefi | B | April 12, 2019, 5:01 p.m. | OK | GNU C++14 | TESTS | 90 | 109 | 409600 | 1900 | |
51493569 | rich_and_yuong | B | March 19, 2019, 2:46 p.m. | OK | GNU C++14 | TESTS | 90 | 109 | 409600 | 1900 | |
47434106 | ferin | B | Dec. 23, 2018, 5:45 p.m. | OK | GNU C++14 | TESTS | 90 | 109 | 409600 | 1900 | |
59658431 | lukamosiashvili | B | Aug. 29, 2019, 11:27 a.m. | OK | GNU C++17 | TESTS | 90 | 93 | 409600 | 1900 | |
59408825 | cheissmart | B | Aug. 24, 2019, 2:57 p.m. | OK | GNU C++17 | TESTS | 90 | 93 | 409600 | 1900 | |
56399098 | svlads | B | July 1, 2019, 4 p.m. | OK | GNU C++17 | TESTS | 90 | 93 | 409600 | 1900 | |
51904957 | alireza_kaviani | B | March 27, 2019, 3:03 p.m. | OK | GNU C++17 | TESTS | 90 | 108 | 614400 | 1900 | |
48113830 | Umm | B | Jan. 9, 2019, 11:21 a.m. | OK | GNU C++17 | TESTS | 90 | 109 | 307200 | 1900 | |
54148559 | loyolman | B | May 14, 2019, 9:16 p.m. | OK | GNU C++17 | TESTS | 90 | 109 | 409600 | 1900 | |
45297129 | Arterm | B | Nov. 4, 2018, 7:13 p.m. | OK | GNU C++17 | TESTS | 90 | 109 | 409600 | 1900 | |
45300306 | KADR | B | Nov. 4, 2018, 7:47 p.m. | OK | GNU C++17 | TESTS | 90 | 109 | 614400 | 1900 | |
45292256 | LHiC | B | Nov. 4, 2018, 6:32 p.m. | OK | GNU C++17 | TESTS | 90 | 109 | 614400 | 1900 | |
55311553 | AST_TheCoder | B | June 8, 2019, 5:58 p.m. | OK | GNU C++17 | TESTS | 90 | 109 | 7782400 | 1900 | |
45294324 | ilyakor | B | Nov. 4, 2018, 6:48 p.m. | OK | Java 8 | TESTS | 90 | 187 | 0 | 1900 | |
45297128 | qwerty787788 | B | Nov. 4, 2018, 7:13 p.m. | OK | Java 8 | TESTS | 90 | 218 | 0 | 1900 | |
45296067 | liymbear | B | Nov. 4, 2018, 7:02 p.m. | OK | Java 8 | TESTS | 90 | 233 | 0 | 1900 | |
45290914 | Petr | B | Nov. 4, 2018, 6:24 p.m. | OK | Java 8 | TESTS | 90 | 234 | 0 | 1900 | |
49651329 | vjudge4 | B | Feb. 9, 2019, 7:47 a.m. | OK | MS C++ | TESTS | 90 | 218 | 0 | 1900 |
Back to search problems