Programming-Idioms

History of Idiom 2 > diff from v47 to v48

Edit summary for version 48 :
[Elixir] fix documentation link

Version 47

2016-09-06, 15:10:23

Version 48

2016-09-06, 15:12:19

Idiom #2 Print Hello 10 times

Loop to execute some code a constant number of times

Idiom #2 Print Hello 10 times

Loop to execute some code a constant number of times

Code
for _ <- 1..10 do IO.puts "hello" end
Code
for _ <- 1..10 do IO.puts "hello" end
Doc URL
http://elixir-lang.org/docs/stable/elixir/Enum.html#each/2
Doc URL
http://elixir-lang.org/docs/stable/elixir/Kernel.SpecialForms.html#for/1