A great example of an idempotent function is the absolute value function. abs(-4) = 4 abs(4) = 4. Continuing to apply abs() onto itself will always yield the same result.
abs(-4) = 4
abs(4) = 4
For those that have done some Elixir before: -4 |> abs |> abs |> ... will always yield 4
-4 |> abs |> abs |> ...
We're a place where coders share, stay up-to-date and grow their careers.
We strive for transparency and don't collect excess data.