Comments on Are All Elements Equal?[FINALIZED]
Post
Are All Elements Equal?[FINALIZED]
+3
−0
Challenge
Given a list of integers >= 0 , check if all of them are equal.
Tests
[1,1,1,1,1] -> true
[0,1,1,6,7] -> false
[1] -> true
[] -> undefined(you do not need to handle this)
You may take the integers in any form(strings, list, codepoints, etc.)
You can output two distinct values for true or false, or simply a truthy or falsy value in your language.
Trivial builtins are allowed, but it is encouraged to edit them into the trivial builtins answer, or try a different approach.
1 comment thread