I have just found a very strange solution for CSES — Elevator Rides problem and I think there will be someone can hack this, please help xxx. https://cses.fi/paste/e5c0ddf5c0b47ad42a1d2f/
| # | User | Rating |
|---|---|---|
| 1 | Benq | 3676 |
| 2 | Kevin114514 | 3659 |
| 3 | jiangly | 3640 |
| 4 | turmax | 3450 |
| 5 | tourist | 3382 |
| 6 | strapple | 3360 |
| 7 | Um_nik | 3354 |
| 8 | squareOf105 | 3348 |
| 9 | maroonrk | 3312 |
| 10 | idontwannadothis…e | 3191 |
| # | User | Contrib. |
|---|---|---|
| 1 | Qingyu | 155 |
| 2 | nik_exists | 151 |
| 3 | maspy | 149 |
| 4 | AmShZ | 145 |
| 5 | Um_nik | 143 |
| 6 | Errichto | 139 |
| 7 | BledDest | 136 |
| 8 | adamant | 134 |
| 9 | maroonrk | 132 |
| 10 | cry | 130 |
I have just found a very strange solution for CSES — Elevator Rides problem and I think there will be someone can hack this, please help xxx. https://cses.fi/paste/e5c0ddf5c0b47ad42a1d2f/
| Name |
|---|



this is my code, but I can't calculate the probability to get wrong answer.
This seems to work:
The idea is that you need to group together each block of the same number, so if you combine two different numbers, which is highly likely, then you immediately fail. The numbers are chosen so that you have a group of $$$5$$$ numbers, a group of $$$7$$$ numbers, and a group of $$$8$$$ numbers, each of which are all the same number, where each group adds up to the same total and the numbers are coprime so that they're forced to be in those groups.
The above testcase consistently fails the given code, but if you increase the number of iterations from $$$10^5$$$ to $$$10^6$$$ then it consistently passes. However, you can fail even $$$10^6$$$ iterations using the following similar case:
This case has a group of $$$3$$$ numbers, a group of $$$4$$$ numbers, a group of $$$5$$$ numbers, and a group of $$$7$$$ numbers.