n. Reverse it, then reverse the result once more. Return true if you end up with n again, and false otherwise.n=4071 → True
4071 → 1704 → 4071: the number comes back to itself.
n=350 → False
350 → 53 (the leading zero is dropped) → 35, which is not 350.
n=0 → True
Zero stays zero when reversed.
n ≤ 10¹²n=4071
True
Run checks the first 3 tests in your browser. Submit checks all 69 tests on the server, hidden ones included.