Recovered from cvs revision 2007-05-01 07:40:00
This commit is contained in:
7
ase/test/awk/emp-025.awk
Normal file
7
ase/test/awk/emp-025.awk
Normal file
@ -0,0 +1,7 @@
|
||||
$2 > 6 { n = n + 1; pay = pay + $2 * $3; }
|
||||
END { if (n > 0)
|
||||
print n, "employees, total pay is", pay,
|
||||
"average pay is", pay/n;
|
||||
else
|
||||
print "no employees are paid more than $6/hour";
|
||||
}
|
Reference in New Issue
Block a user