My doubt is that if the len(list) calculates the length of the list everytime it is called or it returns the value of the builtin counter.
I have a context where i need to check the length of list everytime in a loop, like
listData = []
for value in ioread():
    if len(listData)>=25:
        processlistdata()
        clearlistdata()
    listData.append(value)