Not to take from all the funny answers … but
bool IsEven(int i) => (i & 1) != 1;
(C#)
Master of Applied Cuntery, Level 7 Misanthrope, and Social Injustice Warrior
Not to take from all the funny answers … but
bool IsEven(int i) => (i & 1) != 1;
(C#)
I like to style visited links blue and unvisited links purple, just to mess with people.
Though, obviously I had to come up with some ridiculous solutions:
bool IsEven(int i) => ((Func<string, bool>)(s => s[^1] == 48))($"{i:B}");
This one works without conditionals :)
bool IsEven(int i) { try { int _ = (i & 1) / (i & 1); } catch (Exception) { return true; } return false; }