Agreed. That's how I would write it in a professional codebase. I added it to show the transformation from separate functions -> LINQ one-liner. Cheers!
Having things on one line is not an upside. Just think of all the Bash one-liners that are write once edit never. Doubly so in what's essentially a tutorial.
My intention wasn’t to promote one-liners as a best practice, but to illustrate how declarative style can evolve from imperative code.
In production, I agree that clarity should come first.