codeberg.org/fakefred/wikt-cli
loc nearly tripled, so has cursedness

nevertheless, having fun implementing pipes with

also just so that you're aware, if you do

def out_func():
funcs = []
for x in [0, 1]:
var = x
def in_func():
return var
funcs.append(in_func)
return funcs

print([f() for f in out_func()])

this looks like it's gonna print [0, 1] but it's not. It's gonna give you [1, 1].

@trickster @fakefred Just checking I understand: this might work properly if out_func was a generator rather than returning a list right?

Follow

@trickster @fakefred "Properly" should be "as intended" because this isn't proper clearly hahahha

· · Web · 0 · 0 · 0
Sign in to participate in the conversation
Mastodon for Tech Folks

This Mastodon instance is for people interested in technology. Discussions aren't limited to technology, because tech folks shouldn't be limited to technology either!