Wouldn’t rand # & mod combo compile faster than nextBoolean?
6
Anonymous14w
Crash out
5
Anonymous14w
Something I like doing is splitting the ternary operator over multiple lines. Best of both worlds. Like this:
return random.nextBoolean()
? a
: b;
5
Anonymous14w
was there any justification?
3
Anonymous14w
Didn’t even omit the else block 💔💔
3
Anonymous14w
His is more quickly understandable
1
Anonymous14w
The first line isn’t even that hard to understand and is a lot cleaner. Your teammate is crazy
1
Anonymous#214w
He didn’t see it he said
9
Anonymous#614w
The one liner is way quicker to read. I don’t think we should stop using ternary operators just because some people are too lazy to understand what they mean even though it’s ridiculously simple