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 |
---|---|---|---|---|---|---|
489 | Codeforces Round 277.5 (Div. 2) | FINISHED | False | 9000 | 321200687 | Nov. 17, 2014, 3:35 p.m. |
Solved$ |
Index |
Name |
Type |
Tags |
Community Tag |
Rating |
---|---|---|---|---|---|---|
( 6733 ) | D | Unbearable Controversy of Being | PROGRAMMING | brute force combinatorics dfs and similar graphs | 1700 |
B'Tomash keeps wandering off and getting lost while he is walking along the streets of Berland. It 's no surprise! In his home town, for any pair of intersections there is exactly one way to walk from one intersection to the other one. The capital of Berland is very different! Tomash has noticed that even simple cases of ambiguity confuse him. So, when he sees a group of four distinct intersections a, b, c and d, such that there are two paths from a to c -- one through b and the other one through d, he calls the group a "damn rhombus". Note that pairs (a, xe2 x80 x89b), (b, xe2 x80 x89c), (a, xe2 x80 x89d), (d, xe2 x80 x89c) should be directly connected by the roads. Schematically, a damn rhombus is shown on the figure below: Other roads between any of the intersections don 't make the rhombus any more appealing to Tomash, so the four intersections remain a "damn rhombus" for him. Given that the capital of Berland has n intersections and m roads and all roads are unidirectional and are known in advance, find the number of "damn rhombi" in the city. When rhombi are compared, the order of intersections b and d doesn 't matter. The first line of the input contains a pair of integers n, m (1 xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89n xe2 x80 x89 xe2 x89 xa4 xe2 x80 x893000, xe2 x80 x890 xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89m xe2 x80 x89 xe2 x89 xa4 xe2 x80 x8930000) -- the number of intersections and roads, respectively. Next m lines list the roads, one per line. Each of the roads is given by a pair of integers ai, xe2 x80 x89bi (1 xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89ai, xe2 x80 x89bi xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89n;ai xe2 x80 x89 xe2 x89 xa0 xe2 x80 x89bi) -- the number of the intersection it goes out from and the number of the intersection it leads to. Between a pair of intersections there is at most one road in each of the two directions. It is not guaranteed that you can get from any intersection to any other one. Print the required number of "damn rhombi".'... |
Codeforces Round #277.5 (Div. 2) Editorial [A-D for now] |
Submission Id |
Author(s) |
Index |
Submitted |
Verdict |
Language |
Test Set |
Tests Passed |
Time taken (ms) |
Memory Consumed (bytes) |
Tags |
Rating |
---|---|---|---|---|---|---|---|---|---|---|---|
41881490 | luogu_bot2 | D | Aug. 20, 2018, 1:50 a.m. | OK | FPC | TESTS | 31 | 46 | 4812800 | 1700 | |
41881466 | vjudge3 | D | Aug. 20, 2018, 1:49 a.m. | OK | FPC | TESTS | 31 | 46 | 4812800 | 1700 | |
40987645 | ReaLNero1 | D | July 30, 2018, 9:23 p.m. | OK | GNU C++ | TESTS | 31 | 31 | 307200 | 1700 | |
41925807 | vjudge1 | D | Aug. 21, 2018, 7:22 a.m. | OK | GNU C++ | TESTS | 31 | 61 | 307200 | 1700 | |
42445413 | Schiwon | D | Sept. 4, 2018, 2:37 a.m. | OK | GNU C++ | TESTS | 31 | 62 | 307200 | 1700 | |
41002163 | vjudge5 | D | July 31, 2018, 7:42 a.m. | OK | GNU C++ | TESTS | 31 | 62 | 409600 | 1700 | |
40028102 | vjudge4 | D | July 6, 2018, 11:17 a.m. | OK | GNU C++ | TESTS | 31 | 62 | 73011200 | 1700 | |
41544043 | CazadorDivino | D | Aug. 13, 2018, 2:45 a.m. | OK | GNU C++ | TESTS | 31 | 124 | 819200 | 1700 | |
41544092 | CazadorDivino | D | Aug. 13, 2018, 2:47 a.m. | OK | GNU C++ | TESTS | 31 | 140 | 716800 | 1700 | |
56537061 | Hongzy | D | July 5, 2019, 1:57 a.m. | OK | GNU C++11 | TESTS | 31 | 31 | 307200 | 1700 | |
53804779 | LudwigVanBeethoven | D | May 5, 2019, 10:55 p.m. | OK | GNU C++11 | TESTS | 31 | 31 | 307200 | 1700 | |
56513746 | vjudge1 | D | July 4, 2019, 11:44 a.m. | OK | GNU C++11 | TESTS | 31 | 46 | 307200 | 1700 | |
53038430 | tsingcbx | D | April 20, 2019, 8:31 a.m. | OK | GNU C++11 | TESTS | 31 | 46 | 307200 | 1700 | |
47534176 | AK. | D | Dec. 26, 2018, 10:32 p.m. | OK | GNU C++11 | TESTS | 31 | 46 | 307200 | 1700 | |
42463814 | mernazakaria | D | Sept. 4, 2018, 2:52 p.m. | OK | GNU C++11 | TESTS | 31 | 46 | 307200 | 1700 | |
42253584 | skmonir | D | Aug. 29, 2018, 7:12 p.m. | OK | GNU C++11 | TESTS | 31 | 46 | 307200 | 1700 | |
59000870 | XZ20220135 | D | Aug. 18, 2019, 1:40 p.m. | OK | GNU C++11 | TESTS | 31 | 46 | 512000 | 1700 | |
44536711 | linkedroot | D | Oct. 19, 2018, 9:17 a.m. | OK | GNU C++11 | TESTS | 31 | 46 | 512000 | 1700 | |
69653742 | Pyqe | D | Jan. 28, 2020, 6:31 a.m. | OK | GNU C++11 | TESTS | 31 | 46 | 614400 | 1700 | |
46987245 | _you_tee_ | D | Dec. 13, 2018, 9:26 p.m. | OK | GNU C++14 | TESTS | 31 | 31 | 512000 | 1700 | |
42425184 | kashyap_archit | D | Sept. 3, 2018, 12:22 p.m. | OK | GNU C++14 | TESTS | 31 | 31 | 512000 | 1700 | |
42236495 | jcode777 | D | Aug. 29, 2018, 10:01 a.m. | OK | GNU C++14 | TESTS | 31 | 31 | 512000 | 1700 | |
41125451 | vaibh1297 | D | Aug. 2, 2018, 2:02 p.m. | OK | GNU C++14 | TESTS | 31 | 31 | 512000 | 1700 | |
47322188 | daddy_is_home | D | Dec. 21, 2018, 8:25 a.m. | OK | GNU C++14 | TESTS | 31 | 31 | 716800 | 1700 | |
57968340 | paranoid123 | D | July 30, 2019, 4:13 a.m. | OK | GNU C++14 | TESTS | 31 | 46 | 307200 | 1700 | |
53561574 | vjudge4 | D | April 30, 2019, 9:51 a.m. | OK | GNU C++14 | TESTS | 31 | 46 | 307200 | 1700 | |
48924142 | O.S.Mozes | D | Jan. 25, 2019, 9:25 a.m. | OK | GNU C++14 | TESTS | 31 | 46 | 409600 | 1700 | |
48397027 | varun_raj | D | Jan. 14, 2019, 6:17 p.m. | OK | GNU C++14 | TESTS | 31 | 46 | 409600 | 1700 | |
60839539 | HocSinhChuyenTin | D | Sept. 19, 2019, 10:22 a.m. | OK | GNU C++14 | TESTS | 31 | 46 | 512000 | 1700 | |
45468139 | gtpan77 | D | Nov. 9, 2018, 7:37 a.m. | OK | GNU C++17 | TESTS | 31 | 31 | 512000 | 1700 | |
69940115 | vjudge2 | D | Feb. 1, 2020, 5:50 a.m. | OK | GNU C++17 | TESTS | 31 | 46 | 307200 | 1700 | |
56639168 | yuhta | D | July 6, 2019, 11 p.m. | OK | GNU C++17 | TESTS | 31 | 46 | 409600 | 1700 | |
69607462 | 25ghost | D | Jan. 27, 2020, 10:16 a.m. | OK | GNU C++17 | TESTS | 31 | 46 | 512000 | 1700 | |
68029156 | StiveMan | D | Jan. 1, 2020, 8:05 a.m. | OK | GNU C++17 | TESTS | 31 | 46 | 512000 | 1700 | |
67478617 | newvar | D | Dec. 23, 2019, 3:13 p.m. | OK | GNU C++17 | TESTS | 31 | 46 | 512000 | 1700 | |
67403048 | Chaska | D | Dec. 22, 2019, 5:03 a.m. | OK | GNU C++17 | TESTS | 31 | 46 | 512000 | 1700 | |
66585028 | hdsingharora99 | D | Dec. 10, 2019, 10:50 a.m. | OK | GNU C++17 | TESTS | 31 | 46 | 512000 | 1700 | |
66071451 | Saraw | D | Nov. 30, 2019, 7:44 p.m. | OK | GNU C++17 | TESTS | 31 | 46 | 512000 | 1700 | |
62392015 | kesp | D | Oct. 12, 2019, 2:57 a.m. | OK | GNU C++17 | TESTS | 31 | 46 | 512000 | 1700 | |
59913327 | saurabhs1206 | D | Sept. 2, 2019, 6:06 p.m. | OK | Java 8 | TESTS | 31 | 140 | 38502400 | 1700 | |
53496443 | ShowStopper728 | D | April 29, 2019, 12:02 p.m. | OK | Java 8 | TESTS | 31 | 155 | 0 | 1700 | |
50692857 | ZeyadKhattab | D | March 2, 2019, 4:31 p.m. | OK | Java 8 | TESTS | 31 | 155 | 0 | 1700 | |
39657817 | StayAwayFromBitches | D | June 25, 2018, 6:30 p.m. | OK | Java 8 | TESTS | 31 | 155 | 0 | 1700 | |
50692822 | ZeyadKhattab | D | March 2, 2019, 4:30 p.m. | OK | Java 8 | TESTS | 31 | 156 | 0 | 1700 | |
43053047 | Ahmad | D | Sept. 19, 2018, 12:12 a.m. | OK | Java 8 | TESTS | 31 | 186 | 0 | 1700 | |
53585683 | Ziklon | D | April 30, 2019, 6:21 p.m. | OK | Java 8 | TESTS | 31 | 187 | 0 | 1700 | |
42749113 | Ahmed.Shawky | D | Sept. 10, 2018, 10:43 p.m. | OK | Java 8 | TESTS | 31 | 202 | 0 | 1700 | |
69881015 | dkcs | D | Jan. 31, 2020, 6:21 a.m. | OK | Java 8 | TESTS | 31 | 233 | 0 | 1700 | |
59263376 | Sasuke-u | D | Aug. 22, 2019, 9:35 a.m. | OK | Java 8 | TESTS | 31 | 233 | 0 | 1700 | |
51675391 | toysheeyeyraku | D | March 22, 2019, 10:13 a.m. | OK | Mono C# | TESTS | 31 | 685 | 44339200 | 1700 | |
53050097 | vjudge2 | D | April 20, 2019, 2:10 p.m. | OK | MS C++ | TESTS | 31 | 46 | 307200 | 1700 | |
58104848 | vjudge1 | D | Aug. 1, 2019, 3:31 a.m. | OK | MS C++ | TESTS | 31 | 62 | 36659200 | 1700 | |
39888542 | Volpe | D | July 3, 2018, 8:56 a.m. | OK | MS C++ | TESTS | 31 | 77 | 36659200 | 1700 | |
57969181 | vjudge3 | D | July 30, 2019, 4:54 a.m. | OK | MS C++ | TESTS | 31 | 78 | 1228800 | 1700 | |
58818312 | vjudge4 | D | Aug. 14, 2019, 1:15 p.m. | OK | MS C++ | TESTS | 31 | 93 | 307200 | 1700 | |
53125960 | vjudge5 | D | April 22, 2019, 2:01 p.m. | OK | MS C++ | TESTS | 31 | 156 | 409600 | 1700 | |
57979384 | vjudge4 | D | July 30, 2019, 8:48 a.m. | OK | MS C++ | TESTS | 31 | 187 | 72396800 | 1700 | |
57733272 | vjudge1 | D | July 25, 2019, 9:11 a.m. | OK | MS C++ | TESTS | 31 | 202 | 61337600 | 1700 | |
46681266 | vjudge4 | D | Dec. 6, 2018, 12:11 p.m. | OK | MS C++ | TESTS | 31 | 296 | 39628800 | 1700 | |
66737643 | pikachan14 | D | Dec. 12, 2019, 7:39 p.m. | OK | MS C++ 2017 | TESTS | 31 | 202 | 36454400 | 1700 | |
58868355 | jay__0208 | D | Aug. 15, 2019, 2:17 p.m. | OK | PyPy 2 | TESTS | 31 | 249 | 5120000 | 1700 | |
62282293 | kabeer27 | D | Oct. 10, 2019, 12:57 p.m. | OK | PyPy 2 | TESTS | 31 | 280 | 4403200 | 1700 | |
65390441 | UTMoonlight | D | Nov. 19, 2019, 5:21 p.m. | OK | PyPy 3 | TESTS | 31 | 280 | 5324800 | 1700 | |
62118714 | abreddy | D | Oct. 8, 2019, 2:04 p.m. | OK | PyPy 3 | TESTS | 31 | 467 | 7680000 | 1700 |
Back to search problems