Quick actions

cmd+k|ctrl+k

Navigation

Languages

Elixir pattern matching

Snippet info

Language

Elixir

Visibility

public

Author

jsonkody

Created

2024-07-31T14:04:54.890095Z

Updated

2024-07-31T14:04:54.890095Z

# x = {:err, "ne neni to ok, je to chybaaa"}
x = {:ok, "ano je to ok"}

case x do
    {:ok, msg} -> IO.puts(msg)
    {:err, msg} -> IO.puts(msg)
end
INFO