with ada.text_io; use ada.text_io; 
with ada.integer_text_io; use ada.integer_text_io; 
with ada.float_text_io; use ada.float_text_io; 
 
procedure emp4  is 
    type Employee is record
        name: String(1..20);
        id: String(1..6);
        salary: Float;
    end record;

    type EmpArray is array(1 .. 100) of Employee;

    e: Employee;
    theEmployees: EmpArray;
    count: Natural := 0;
begin
    skip_line;
    while not end_of_file loop
        get(e.name);
        get(e.id);
        get(e.salary);

        count := count + 1;
        theEmployees(count) := e;
    end loop;

    -- for i in reverse 1 .. theEmployees'last loop
    for i in reverse 1 .. count loop
        e := theEmployees(i);
        if e.salary > 100_000.00 then
            put(e.name);
            put(e.id);
            put(e.salary, fore=> 7, aft=> 2, exp=>0);
            new_line;
        end if;
    end loop;
end emp4;