Skip to content

Instantly share code, notes, and snippets.

@mulderu
Created February 13, 2025 22:07
Show Gist options
  • Save mulderu/0577f93f3bef620ea926f03a85e53b1d to your computer and use it in GitHub Desktop.
Save mulderu/0577f93f3bef620ea926f03a85e53b1d to your computer and use it in GitHub Desktop.
elixir snipet

learn

iex> states = %{"AL" => "Alabama",
%{"AL" => "Alabama", "WI" => "Wisconsin"}
"WI" => "Wisconsin" }
iex> responses = %{ { :error, :enoent } => :fatal, { :error, :busy } => :retry }
%{{:error, :busy} => :retry, {:error, :enoent} => :fatal}
iex> colors = %{ :red => 0xff0000, :green => 0x00ff00, :blue => 0x0000ff }
%{blue: 255, green: 65280, red: 16711680}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment