qck.hlp (Table of Contents; Topic list)
Numeric Constants
                                                 Contents  Index  Back
──────────────────────────────────────────────────────────────────────────────
 Numeric Constants
 
 ■ Numeric constants are positive or negative numbers and cannot contain
   commas.
 
   Type               Description
   ══════════════════ ══════════════════════════════════════════════════════
   Integer            One or more decimal digits (0-9), with an optional sign
   (decimal)          prefix  (+ or -). The range for integer decimal
                      constants is -32,768 to 32,767.
 
   Integer            One or more hexadecimal digits (0-9, a-f, or A-F) with
   (hexadecimal)      the prefix &H or &h. The range for integer hexadecimal
                      constants is &h0 to &hFFFF.
 
   Integer            One or more octal digits (0-7) with the prefix &O, &o,
   (octal)            or &. The range for integer octal constants is &o0 to
                      &o177777.
 
   Long integer       One or more decimal digits (0-9), with an optional sign
   (decimal)          prefix (+ or -) and the suffix &. The range for long
                      decimal constants is -2,147,483,648 to 2,147,483,647.
 
   Long integer       One or more hexadecimal digits (0-9, a-f, or A-F) with
   (hexadecimal)      the prefix &H or &h and the suffix &. The range for
                      long hexadecimal constants is &h0& to &hFFFFFFFF&.
 
   Long integer       One or more octal digits (0-7) with the prefix &O, &o,
   (octal)            or & and the suffix &. The range for long octal
                      constants is &o0& to &o37777777777&.
 
   Fixed point        Positive or negative real numbers (numbers containing
                      decimal points).
 
   Currency           Positive or negative real numbers (numbers containing
                      decimal points) with the suffix @, (fixed-point number)
                      stored with 19 digits of precision; maximum 4 digits to
                      the right of the decimal point and up to 15 digits on
                      the left, possessing one of the following properties:
                      • Fixed-point form: maximum 4 digits to the right of the
                        decimal point, within the currency data type range,
                        and a trailing at sign (@)
                      • Integer form (no decimal point): within the currency
                        data type range, and a trailing at sign (@)
                      The range for currency constants is
                      -922337203685477.5808 to 922337203685477.5807.
 
   Floating point     Positive or negative numbers represented in exponential
   (single-precision) form. A single-precision floating-point constant is an
                      optionally signed integer or fixed-point number (the
                      mantissa) followed by the letter E and an optionally
                      signed integer (the exponent). The constant's value is
                      the mantissa multiplied by the power of ten represented
                      by the exponent. Single-precision constants have a
                      range of -3.40E38 to 3.40E38. A single-precision
                      numeric constant possesses one of the following
                      properties:
                      • Exponential form (denoted by E)
                      • A trailing exclamation mark (!)
                      • A value containing a decimal point that does not have
                        a D in the exponent or a trailing number sign (#),
                        and has more than 15 digits
                      • A value (without a decimal point) fewer than 15
                        digits, but cannot be represented as a long integer
 
   Floating point     Double-precision floating-point constants have the same
   (double-precision) form as single-precision floating-point constants, but
                      use D, rather than E, to indicate the exponent. Double-
                      precision constants have a range of -1.79D308 to
                      1.79D308. A double-precision numeric constant possesses
                      one of the following properties:
                      • Exponential form (denoted by D)
                      • A trailing number sign (#)
                      • A decimal point, no E in the exponent or trailing
                        exclamation mark (!), and more than 15 digits
 
 ■ Integers (2-byte) and long integers (4-byte) can also be used in numeric
   expressions. However, unlike the numeric constants described above,
   integers become part of the generated code and are not stored in memory.
 
 See: Constants Summary