Alexandre B A Villares 🐍
883b5e42e69fa4eb2bee76e555c217028b48dc7676f61453c7f506fd1a33ab62
PT: Educador de tec. e artes, pesquisa práticas artísticas que se valem de meios computacionais e ensino de programação em contextos visuais. Co-organizador da Noite de Processing. Doutorando na FECFAU-Unicamp.
EN: Tech and art educator, researcher of artistic work that makes use of computational means and how to teach programming in a visual context. Co-organizer of Noite de Processing. PhD candidate at FECFAU-Unicamp.
#SãoPaulo #Processing #Python #py5 #ForaBluetooth #CreativeCoding #FLOSS
nostr:npub1qcxmjzt90y8g3kwych8r8x4wf0s6chm4z27ftgglxqcr4e7mhf5svwxq0z putz que bode desse Harari
nostr:npub1mjjwe95dghhw434k4vsvxs5yl6gcr6kupghf5u0dgcvhga0w94sqe7h2pr I'd say this isn't performant because it copies the string unnecessarily.
nostr:npub1dnc2khknlklurqv25dyzpyh4qcdr3l92tvzm4xh56nuhh3cdtuaq06ycxc I'm more concerned about clarity/legibility than performance as this will tackle a list of a few dozen lines/items only.
Seems OK to me... #Python
with open(text_file) as f:
items = [line for line in f.read().splitlines()
if line.strip() and not line.startswith('#')]
Context: A txt file with a list of files to process, some are commented out, and there is a first line head comment followed by a blank line.