| # | User | Rating |
|---|---|---|
| 1 | jiangly | 3810 |
| 2 | Benq | 3676 |
| 3 | Kevin114514 | 3655 |
| 4 | maroonrk | 3463 |
| 5 | strapple | 3447 |
| 6 | Um_nik | 3387 |
| 7 | heuristica | 3322 |
| 8 | turmax | 3317 |
| 9 | tourist | 3307 |
| 10 | jiangbowen | 3291 |
| # | User | Contrib. |
|---|---|---|
| 1 | Qingyu | 156 |
| 2 | nik_exists | 150 |
| 2 | maspy | 150 |
| 4 | Um_nik | 142 |
| 5 | Errichto | 139 |
| 6 | adamant | 137 |
| 7 | AmShZ | 135 |
| 8 | BledDest | 132 |
| 8 | maroonrk | 132 |
| 10 | qwexd | 129 |
|
+10
You are right about that. I think repeatedly removing leaves of the graph until only nodes of degree $$$\geq 2$$$ are left will reduce the amount of paths by an order of $$$n$$$, since the sum of degrees of all nodes will be $$$\leq 2n+20$$$, and the maximum degree of any node will also be 20. It should pass within the time limit now. |
|
+10
Alternative solution for F: After seeing that the edges colored 1 and 2 must form a cycle, we also observe that this cycle must have length $$$\leq m-n+1$$$. This is because the graph still needs to be connected after removing the cycle. The minimum number of edges needed for a graph of size $$$n$$$ to be connected is $$$n-1$$$ edges, so if the cycle was more than $$$m-n+1$$$ edges long, it is impossible for the graph to be connected after removing them. So, we just run a dfs starting from each node, with a max depth of 10, finding every cycle candidate containing that node. The complexity should be the same as in the official solution. Submission: 390181201 |
| Name |
|---|


