There was one thing with block chaining that I was really hoping they'd hit on. They didn't. They had:
# good
names.select { |name| name.start_with?("S") }.map { |name| name.upcase }
I've noticed that sort of chaining is changing towards:
names.select { |name| name.start_with?("S") }
.map { |name| name.upcase }
Which can be further chained (if need be) like so:
names.select { |name| name.start_with?("S") }
.map { |name| name.upcase }
.sort
.join(', ')
Which, imo, is just better than trying to do it all on one line or using intermediate variables. It's more of a value call when it comes to the intermediate variables, though. I'd also use
.map(&:upcase)
instead of
.map { |word| word.upcase }
But I think it's perfectly understandable if you find the word.upcase more explicit and readable.