Skip to content

Instantly share code, notes, and snippets.

@gatarelib
Created August 14, 2019 12:32
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save gatarelib/317bf5931cd6bafa1f045f843c99fd5e to your computer and use it in GitHub Desktop.
Save gatarelib/317bf5931cd6bafa1f045f843c99fd5e to your computer and use it in GitHub Desktop.
Andela assessment Question
const digitize = (n) => {
r = n.toString().split('');
r.forEach((el, i, a) => { a[i] = parseInt(el); })
return r
}
digitize(715) // [7, 1, 5]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment