This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
func pascal(rows) {
var row = [1]
{ | n|
say row.join(' ')
row = [1, {|i| row[i] + row[i+1] }.map(0 .. n-2)..., 1]
} << 1..rows
}
pascal(10)