(* animals.pas - Practice with integer input. * Notes about the program: * We use write & readln to prompt & obtain input. * We use the := operator to assign a calculated value to a variable. * It's a good idea to precede the output with a blank line. *) program animals; var horses, pigs, chickens, total : integer; begin write('How many horses? '); readln(horses); write('How many pigs? '); readln(pigs); write('How many chickens? '); readln(chickens); total := horses + pigs + chickens; writeln(); writeln('You have a total of ', total, ' animals.'); end.