program enumerated1 (input,output);

 

type MonthAbbrev = (jan,feb,mar,apr,may,jun,jul,aug,sep,oct,nov,dec);

     MonthNumber = 1..12;

 

var month : MonthAbbrev;

    monNum : MonthNumber;

  

begin

    monNum := ord(mar);

    writeln (' the number of the month March is ',  monNum);

    for month := jan to dec do

        write (ord(month),' ');

    writeln;

    writeln (' monNum is a subrange of integers from 1..12 ');

    monNum := 1;

    while (monNum <= 12) do

       begin

         write (monNum, ' ');

         monNum := succ(monNum);

       end;

    writeln ();

   end.