Skip to content

Instantly share code, notes, and snippets.

@vhf
Last active April 29, 2021 18:43
Show Gist options
  • Save vhf/7fd181164259d38075cd06bccd64aa18 to your computer and use it in GitHub Desktop.
Save vhf/7fd181164259d38075cd06bccd64aa18 to your computer and use it in GitHub Desktop.
iex(foo@10.12.165.73)29> Node.list |> Enum.map(fn node -> Enum.map(1..100, fn _ -> {us, :pong} = :timer.tc(Node, :ping, [node])
...(foo@10.12.165.73)29> us/2 end)|> Enum.reduce(fn x, sum -> sum + x end) end) |> Enum.map(fn x -> x / 100 end)
[413.585, 436.995]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment