Logo

Programming-Idioms

  • Clojure
items.forEach(doSomething);
(map do-something items)

do-something should be a function that receives a single argument. map returns a lazy seq, which means the function do-something won't be applied until the results are needed.
for Item of Items loop
   Do_Something (Item);
end loop;

New implementation...