pop() for arrays

Hey everyone,
Im trying to make a buffer with a fixed side, essentially I’m popping the first value, then appending the new value to the end of the array.
For some reason pop() doesn’t seem to work and i’m wondering if this simply isnt in this version of Python? If so how would you recommend making this small buffer?

Thanks for your help!
Pierre Louet

What exactly doesn’t work?

I’ve done this before:

list = []
if len(list) > 4:

This creates a 4 sample buffer.

I have tried this also:
although it says “AttributeError: ‘array’ object has no attribute ‘remove’” which is the same effect as writing pop, could this be a version issue?

Hi, what code are you executing? Did my above code work?

pop() without index removes the last item not the first, try