Closures #
newGreeter = def (greeting)
return def (name)
puts(greeting + " " + name)
end
end
hello = newGreeter("Hello");
hello("dear, future Reader!");
newGreeter = def (greeting)
return def (name)
puts(greeting + " " + name)
end
end
hello = newGreeter("Hello");
hello("dear, future Reader!");