Quantcast
Channel: Hot Weekly Questions - Web Applications Stack Exchange
Viewing all articles
Browse latest Browse all 9786

How to add to each element of an array

$
0
0

I'm trying to take each element of an array that's generated from a SPLIT function and do some math on them, specifically, I want to add 3 to each element.

  1. Cell starts off with this: 1,2,3,4,5
  2. SPLIT function turns this into an array: 1 | 2 | 3 | 4 | 5
  3. Adding 3 to each elements turns it into this: 4 | 5 | 6 | 7 | 8

I've been searching seemingly forever, to no avail. It would be great if there was a simple solution like some kind of increment function that returns another array like this: INCREMENT(SPLIT(AB37,","),3)

Have someone done something like this before?


Viewing all articles
Browse latest Browse all 9786

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>