(* This program illustrates simple use of strings. *)
   (* As in the other examples, the reserved words are in upper case. *)
   (* This is a convention, not a requirement. *)
   
PROGRAM stringTest (input, output);
   TYPE myString = PACKED ARRAY [-3..5] OF char;
   VAR  stringA  : String;
        stringE  : String[1..5];  (* causes a compile error *)
        stringF  : String[-3];    (* causes a compile error - length must be positive *)
   s     stringB  : String[15];    
        stringC  : String[5];
        stringD  : myString;
BEGIN
    stringA := 'cat';
    writeln ('*', stringA, '*');
    stringB := 'house';
    writeln ('*', stringB, '*'); 
 
    stringB := 'house';
    writeln ('*', stringB, '*'); 

    stringD := '12345678987aaaaaaaa';  
    writeln ('*', stringD, '*');

    stringC := 'hose';
    writeln ('*', stringC, '*'); 

    stringC := 'cat';
    writeln ('*', stringC, '*'); 
    
    stringC := 'houseful';
    writeln ('*', stringC, '*'); 
END.