-- Chapter 30 - Program 4 with Text_IO; use Text_IO; procedure EnumRep is package Int_IO is new Text_IO.Integer_IO(INTEGER); use Int_IO; type MOTION is (STOPPED, NORTH, EAST, SOUTH, WEST); for MOTION use (STOPPED => 0, NORTH => 1, EAST => 2, SOUTH => 4, WEST => 8); Robot_Direction : MOTION := STOPPED; begin Robot_Direction := MOTION'LAST; -- WEST Robot_Direction := MOTION'PRED(Robot_Direction); -- SOUTH end EnumRep; -- Result of execution -- (There is no output from this program)