- 15 x - 7 - -1 = -15 - -7 - -15 x -1 ? Why ? (Name Property)
Answers
A numeric literal is a character-string whose characters are selected from the digits 0 through 9, a sign character (+ or -), and the decimal point.
If the literal contains no decimal point, it is an integer. (In this documentation, the word integer appearing in a format represents a numeric literal of nonzero value that contains no sign and no decimal point, except when other rules are included with the description of the format.) The following rules apply:
If the ARITH(COMPAT) compiler option is in effect, one through 18 digits are allowed. If the ARITH(EXTEND) compiler option is in effect, one through 31 digits are allowed.
Only one sign character is allowed. If included, it must be the leftmost character of the literal. If the literal is unsigned, it is a positive value.
Only one decimal point is allowed. If a decimal point is included, it is treated as an assumed decimal point (that is, as not taking up a character position in the literal). The decimal point can appear anywhere within the literal except as the rightmost character.
The value of a numeric literal is the algebraic quantity expressed by the characters in the literal. The size of a numeric literal is equal to the number of digits specified by the user.
Numeric literals can be fixed-point or floating-point numbers.
Numeric literals are in the numeric data class and category. (Data classes and categories are described under Classes and categories of data.)
Rules for floating-point literal values