minus-squarel3mming@lemmy.worldtoProgrammer Humor@programming.dev•Modern Programminglinkfedilinkarrow-up3arrow-down1·edit-21 day agoYou clearly haven’t used Perl a lot. Perl’s ternary looks like: $even = $num % 2 ? “nay” : “yay”; Incidentally, it is also the same as PHP’s, but mainly because PHP stole it. linkfedilink
You clearly haven’t used Perl a lot. Perl’s ternary looks like:
$even = $num % 2 ? “nay” : “yay”;
Incidentally, it is also the same as PHP’s, but mainly because PHP stole it.