added reduce method to NSArray and NSSet

Return a single value from an array by iterating through the elements
and transforming a running total.
Revert bb7ec4c..44814a0

This rolls back to commit bb7ec4c6a43664ab4215627a16ac6b57aeda277b.