#7DaysJS: myElement + n

twitter logo github logo Originally published at lautarolobo.xyz on ・1 min read

Welcome to day 6 of 7 Days of JavaScript!

Let’s see, I got a nice one for today.

Given an array and a number n, return the array with each element summed to n.

Here’s an example:


If you want, you can also return the output as a string - If that makes it easier for you, it’s OK.

You can check out the solution algorithm here.

twitter logo DISCUSS
Classic DEV Post from Mar 3 '19

A simple caching strategy for Node REST APIs, Part 1

Lautaro Lobo profile image
While you read this I'm learning something new. CS ♥️

👋 Hey dev.to reader.

Do you prefer sans serif over serif?

You can change your font preferences in the "misc" section of your settings. ❤️