Let's say I have this:
function arrSum(){
*code here*
}
How do I write the arrSum function such that it can sum all the integers within a multidimensional array (of variable depth).
I.e.
arrSum([2, 5, [4, 6], 5]) === 22;
I know there must be an answer to this somewhere but I really can't find it. If this is a duplicate please let me know.