This commit makes to use sequence directly instead of using
len(SEQUENCE). The original code works correctly, and it's really
straight forward. However, PEP8 recommends like below. And it
makes code more simple, too.
For sequences, (strings, lists, tuples), use the fact that empty
sequences are false.
Yes: if not seq:
No: if len(seq):
if not len(seq):