On 29/09/15 08:33, Peter Otten wrote:
hide 1 show 2,3,4 hide 5, show 6,7,8 etc.
thanks in advance
You can use del on a slice:
And just for kicks you can use a list comprehension:
print [n for i,n in enumerate(a) if i%4]
hth
--
Alan G
Author of the Learn to Program web site
http://www.alan-g.me.uk/
http://www.amazon.com/author/alan_gauld
Follow my photo-blog on Flickr at:
http://www.flickr.com/photos/alangauldphotos
_______________________________________________
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor