Record Types 69  7.B.  Variant Records  Sometimes we may want to include information in a record structure  which depends on some other information already in the record. We can  define a variant record type which includes additional fields depending  on the value of another field.  The syntax for a record type makes provisions for a  variant part,  implying that a record type may be specified as consisting of several  variants.  This means that different variables, although said to be of the  same type, may assume structures which differ in the number and types  of components.  An update might then be recorded as:  If the record is itself nested within another structure, the naming of  the record variable reflects this structure. For example, assume we wish  to record the most recent smallpox vaccination for each member in a  family. A possibility is to define the members as an enumerated type,  and then keep the dates in an array of records:  type Fami1yMember  =  (Father,  Mother,  Chi1d1,  Child2,  Child3);  var VaccinationDate:  array  [FamilyMember]  of Date;  VaccinationDate[Child3] .Mo  := Apr;  VaccinationDate[Child3] .Day  := 23;  VaccinationDate[Child3] .Year  := 1973  x  =  10.0 -3.0i  Y  =  2.0  5.0i  Sum  12.0  2.0i  Product  =  35.0  44.0i  x  =  14.0 -7.0i  Y  =  2.0  5.0i  Sum  16.0 -2.0i  Product  =  63.0 56.0i  x  =  18.0-11.0i  Y  =  2.0  5.0i  Sum  20.0 -6.0i  Product  =  91.0  68.0i 