[ < ] | [ > ] |  | [ << ] | [ Up ] | [ >> ] |  |  |  |  | [Top] | [Contents] | [Index] | [ ? ]

#### 8.2.10.7 Set Types

    set type identifier = set of set element type;

set type identifier is a set of elements from set element type which is either an ordinal type, an enumerated type or a subrange type. Set element representatives are joined together into a set by brackets:

    [set element, ..., set element]

``[]'` indicates the empty set, which is compatible with all set types. Note: Borland Pascal restricts the maximal set size (i.e. the range of the set element type) to 256, GNU Pascal has no such restriction. The number of elements a set variable is holding can be determined by the intrinsic set function Card (which is a GNU Pascal extension, in Extended Pascal and Borland Pascal you can use SizeOf instead but note the element type size in bytes, then) to the set. There are four intrinsic binary set operations: the union ``+'`, the intersection ``*'` and the difference ``-'`. The symmetric difference ``><'` is an Extended Pascal extension.

### See also

section 9.36 Card, section 9.257 SizeOf

This document was generated by Frank Heckenbach on May, 10 2002 using texi2html