Post History
Are they "if-else statements" or are they "if/else statements"? I'm partial to the latter, but I can see the logic of the former - both "if" and "else" are acting as a unit modifier for the noun "s...
#3: Attribution notice added
Source: https://writers.stackexchange.com/q/33559 License name: CC BY-SA 3.0 License URL: https://creativecommons.org/licenses/by-sa/3.0/
#2: Initial revision
Are they "if-else statements" or are they "if/else statements"? I'm partial to the latter, but I can see the logic of the former - both "if" and "else" are acting as a unit modifier for the noun "statements" (and so a hyphen is appropriate), whereas a slash (usually) indicates an "or" condition. Thoughts?