Ordinal types


 Ordinal types

Turbo Pascal has ten predefined ordinal types:

Five of these integer types denote a specific subset of the whole numbers, as shown here:

   Type     Range                  Size

   Shortint 128..127               8-bit
   Integer  -32768..32767          16-bit
   Longint  -2147483648..2147483647 32-bit
   Byte     0.255                  8-bit
   Word     0.65535                16-bit

The other five predefined ordinal types are the booleans (Boolean, WordBool, LongBool,, ByteBool) and Char.

Two other classes of user-defined ordinal types are enumerated types and subrange types.

These standard functions can be used with all ordinal types:


Тэги: Ordinal Types
| G+
Код для вставки: :: :: :: ::
Поделиться: // //