this post was submitted on 08 Dec 2023
618 points (96.4% liked)

Programmer Humor

32473 readers
558 users here now

Post funny things about programming here! (Or just rant about your favourite programming language.)

Rules:

founded 5 years ago
MODERATORS
 
you are viewing a single comment's thread
view the rest of the comments
[โ€“] [email protected] 1 points 11 months ago (1 children)

Maybe you'r using an older version of Java? Works fine for me.

[โ€“] [email protected] 1 points 11 months ago* (last edited 11 months ago)

New versions of java have a null coalescing operator?

I didn't know that.

Edit: a short search didn't return any answers, as far as I can see java doesn't have this operator, the closest thing is the ternary if operator.