3 ms·
Underscore has been used in programming for the first time by the language IBM PL/I, in 1964-12, where it replaced the hyphen/minus character that was used by C
by adrian_b 2y ago
Underscore has been used in programming for the first time by the language IBM PL/I, in 1964-12, where it replaced the hyphen/minus character that was used by COBOL to make more readable the long identifiers.
Replacing hyphen/minus with underscore has been done precisely for removing the ambiguity with the minus operator (In COBOL the ambiguity was less annoying, because the arithmetic operations were usually written with words, e.g. ADD, SUBTRACT, MULTIPLY and so on).