Student Name:
Formulate the following problems in terms of a map()
,
a fold()
, or a combination of map()
and
fold()
. You do not need to specify the full definition of
your map()
or fold()
; just give a few sentances
on what would be performed by each function.
[(x1, y1),
(x2, y2, z2), ... ]
,
add them to determine the resultant vector. Note that by "vector"
we are referring to a physics vector, e.g., a displacement vector.
[
(empID1, monthID1, monthlyWage1),
(empID1, monthID2, monthlyWage2),
(empID5, monthID5, monthlyWage5),
... ]
, and your output should be of the form [
(empID1, taxOwed1), ... ]
.