Skip to content

Instantly share code, notes, and snippets.

View Inatan's full-sized avatar
🏠
Working from home

Inatan Hertzog Inatan

🏠
Working from home
  • Math Group
  • Porto Alegre, Brazil
View GitHub Profile
@kyanny
kyanny / fib.exs
Created March 13, 2012 01:27
Elixir fibonacci #1
defmodule Fib do
def fib(0) do 0 end
def fib(1) do 1 end
def fib(n) do fib(n-1) + fib(n-2) end
end
IO.puts Fib.fib(10)