 defmodule Typer do
 
   def print(element) when is_tuple(element) do
-    IO.inspect List.to_tuple Enum.map(Tuple.to_list(element), fn x-> print(x) end)
-    
+    IO.inspect List.to_tuple Enum.map(Tuple.to_list(element), fn x-> get_type(x) end)
+    Enum.map(Tuple.to_list(element), fn x-> print(x) end) 
     #    IO.write "{ "
     #    Enum.map(Tuple.to_list(element), fn x-> IO.write(get_type(x) <> ", ") end)
     #    IO.puts " }"

  end

  def print(element) when is_list(element) do
    IO.inspect Enum.map(element, fn x-> print(x) end)
  #    IO.write "[ "
  #    Enum.map(element, fn x-> IO.write(get_type(x) <> ", ") end)
  #    IO.puts " ]"

  def print(element) do
  end

  def get_type(element) when is_tuple(element), do: "tuple" 
  def get_type(element) when is_list(element), do: "list"
  def get_type(element) when is_atom(element), do: "atom"
  def get_type(element) when is_bitstring(element), do: "string"
