Then this should suffice:
Enum.find([1, 2, 3, 5], :not_found, fn x -> x == 3 end)
And then check if :not_found is returned (that value can be anything else btw, it’s just me that picked a default to be returned if nothing is found; it can very easily be an empty map in your original scenario).
Though I also have to remark this: you asking if there’s a break construct in Elixir is a clear sign of the XY problem. Don’t ask how would we do what you think is the solution. Ask us how to achieve your initial goal.






















