Demonstrate me how to write a proper code for this problem


Question: Write a version of this function:

fun sumPairs(nil) = 0

| sumPairs ((x,y)::zs) = x + y + sumPairs(zs);

That sums each component of the pairs individually, returning a pair consisting of the sum of the first components and the sum of the second components. (sum x, sum y)

Can someone demonstrate me how to write a proper code for this problem and how to complete it.

Request for Solution File

Ask an Expert for Answer!!
C/C++ Programming: Demonstrate me how to write a proper code for this problem
Reference No:- TGS0958438

Expected delivery within 24 Hours