Why 0 index hashing is faster than 1 index hashing?

Revision en1, by redheadphone, 2022-07-13 11:28:45

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.net/contest/1701/submission/163370464

Accepted — https://codeforces.net/contest/1701/submission/163370574

TLE — https://codeforces.net/contest/1702/submission/163995656

Accepted — https://codeforces.net/contest/1702/submission/163996134

Tags tle, python, python3, hashing

History

 
 
 
 
Revisions
 
 
  Rev. Lang. By When Δ Comment
en1 English redheadphone 2022-07-13 11:28:45 680 Initial revision (published)