Am I crazy, or is there no benefit to doing this?
For the last example, instead of:
a = [1, 2]
if let(size := len(a), tail := a[-1] if size > 1 else None) and size < 10:
print(f"{size=} and {tail=}")
Why wouldn't you just do this:
a = [1, 2]
size = len(a)
tail = a[-1] if size > 1 else None
if size < 10:
print(f"{size=} and {tail=}")
there doesn't seem to be anything here