withAda.Text_IO;procedureProcess_InputisInput:Ada.Text_IO.File_Type;begin-- Open the input file in read mode.
Ada.Text_IO.Open(Input,Ada.Text_IO.In_File,"input.txt");-- Walk through the file line by line.
whilenotAda.Text_IO.End_Of_File(Input)loopdeclareLine:constantString:=Ada.Text_IO.Get_Line(Input);begin-- Do something with Line.
end;endloop;-- Finally, close the file again.
Ada.Text_IO.Close(Input);endProcess_Input;