PROGRAM EIGHT
Write a program which inputs the ordinary time and overtime worked, calculating the gross pay. The rate is 4.20 per hour, and overtime is time and a half.


	program PROG8 ( input, output );
	var  grosspay, ordinary_time, hourlyrate, overtime, ot_rate: real;

	begin
	     hourlyrate := 4.20;
	     ot_rate    := hourlyrate * 1.5;
	     writeln('Please enter the number of hours worked');
	     readln( ordinary_time );
	     writeln('Please enter the number of overtime hours');
	     readln( overtime );
	     grosspay := (ordinary_time * hourlyrate) + (overtime * ot_rate);
	     writeln('The gross pay is $', grosspay:5:2 )
	end.


Copyright B Brown/P Henry/CIT, 1988-1997. All rights reserved.