Sha256: 395b8778f45bfad39c1dbab8894591b6e9a5c7ec832c20207926f5421af72bc4

Contents?: true

Size: 678 Bytes

Versions: 168

Compression:

Stored size: 678 Bytes

Contents

Implement the `accumulate` operation, which, given a collection and an
operation to perform on each element of the collection, returns a new
collection containing the result of applying that operation to each element of
the input collection.

Given the collection of numbers:

- 1, 2, 3, 4, 5

And the operation:

- square a number (`x => x * x`)

Your code should be able to produce the collection of squares:

- 1, 4, 9, 16, 25

Check out the test suite to see the expected function signature.

## Restrictions

Keep your hands off that collect/map/fmap/whatchamacallit functionality
provided by your standard library!
Solve this one yourself using other basic tools instead.

Version data entries

168 entries across 168 versions & 1 rubygems

Version Path
trackler-2.2.1.180 problem-specifications/exercises/accumulate/description.md
trackler-2.2.1.179 problem-specifications/exercises/accumulate/description.md
trackler-2.2.1.178 problem-specifications/exercises/accumulate/description.md
trackler-2.2.1.177 problem-specifications/exercises/accumulate/description.md
trackler-2.2.1.176 problem-specifications/exercises/accumulate/description.md
trackler-2.2.1.175 problem-specifications/exercises/accumulate/description.md
trackler-2.2.1.174 problem-specifications/exercises/accumulate/description.md
trackler-2.2.1.173 problem-specifications/exercises/accumulate/description.md
trackler-2.2.1.172 problem-specifications/exercises/accumulate/description.md
trackler-2.2.1.171 problem-specifications/exercises/accumulate/description.md
trackler-2.2.1.170 problem-specifications/exercises/accumulate/description.md
trackler-2.2.1.169 problem-specifications/exercises/accumulate/description.md
trackler-2.2.1.167 problem-specifications/exercises/accumulate/description.md
trackler-2.2.1.166 problem-specifications/exercises/accumulate/description.md
trackler-2.2.1.165 problem-specifications/exercises/accumulate/description.md
trackler-2.2.1.164 problem-specifications/exercises/accumulate/description.md
trackler-2.2.1.163 problem-specifications/exercises/accumulate/description.md
trackler-2.2.1.162 problem-specifications/exercises/accumulate/description.md
trackler-2.2.1.161 problem-specifications/exercises/accumulate/description.md
trackler-2.2.1.160 problem-specifications/exercises/accumulate/description.md