
Stella Star 15.95 45 121.22 636.40
Stella Star 15.95 45 121.22 0
How do I correct this? I only need the top entry for Stella.
CLS
DIM emp AS STRING
DIM wage AS SINGLE
DIM hours AS SINGLE
DIM pay AS SINGLE
DIM irs AS SINGLE
DIM tpay AS SINGLE
DIM x AS INTEGER 'variable assignments
PRINT "Name Wage Hours IRS Total Pay" 'headings
PRINT "------ ------ ------ ----- ----------"
DATA "Tom Jones",12.88,45,"Mary Bell",15.96,38 'emp name, wage, and hours (there are six more entries in data)
FOR x = 1 TO 8 'read numbers from eight data entries
READ emp, wage, hours
IF hours <= 40 THEN 'set if first loop
pay = wage * hours 'set first pay rate
ELSE
pay = 40 * wage + 1.5 * wage * (hours - 40)
END IF
irs = ((pay * .16) * 100 \ 1) / 100 'sets IRS amount
tpay = (tpay * 100 \ 1) / 100
PRINT emp, wage, hours, irs, total