Remove an unneeded Enum.map
This commit is contained in:
parent
ace4184758
commit
3eac9fe92a
1 changed files with 1 additions and 1 deletions
|
@ -10,8 +10,8 @@ defmodule Day4Part2 do
|
||||||
|> String.split([" ", "\n"])
|
|> String.split([" ", "\n"])
|
||||||
|> Enum.map(&String.split(&1, ":"))
|
|> Enum.map(&String.split(&1, ":"))
|
||||||
|> Map.new(fn [k, v] -> {k, v} end)
|
|> Map.new(fn [k, v] -> {k, v} end)
|
||||||
|
|> Map.delete("cid")
|
||||||
end)
|
end)
|
||||||
|> Enum.map(&Map.delete(&1, "cid"))
|
|
||||||
|> Enum.filter(&MapSet.subset?(@required, &1 |> Map.keys() |> MapSet.new()))
|
|> Enum.filter(&MapSet.subset?(@required, &1 |> Map.keys() |> MapSet.new()))
|
||||||
|> Enum.count(&valid?/1)
|
|> Enum.count(&valid?/1)
|
||||||
|> IO.puts()
|
|> IO.puts()
|
||||||
|
|
Loading…
Reference in a new issue