This has happened to me twice, where 1 index hashing is getting TLE but 0 index hashing with same logic is getting Accepted. Not sure if it's python issue or hashing complexity.
TLE — https://codeforces.me/contest/1701/submission/163370464
Accepted — https://codeforces.me/contest/1701/submission/163370574
TLE — https://codeforces.me/contest/1702/submission/163995656
Accepted — https://codeforces.me/contest/1702/submission/163996134