• dev_null@lemmy.ml
    link
    fedilink
    arrow-up
    3
    ·
    edit-2
    6 days ago

    Because it’s not one. Ternary operator is A ? B : C, Elvis operator is A ?: C. The same two characters are involved, but both the syntax and effect is different.