Hi!
I couldn't understand why two solutions below works differently.
Problem: https://codeforces.net/contest/1675/problem/F
Two solutions:
- https://codeforces.net/contest/1675/submission/156139655 — Passed, fastest among PyPy 3 64-bit solutions.
- https://codeforces.net/contest/1675/submission/156139626 — TLE
The main difference is in input reading:
- A = {int(e) — 1 for e in input().split()}
- A = {int(e) for e in input().split()}
It would be great to understand what is wrong with the second solution?
Thanks!