I have a function which takes an array. I don't know what the dimensionality of the array is (it could have one, two, three dimensions, who knows how many?)
I would like to be able to determine the number of dimensions in the array, and a generic way of going through the array, perhaps by slicing the array into small arrays of n-1 dimensions.
Perhaps 100 points is too low, but let's see what kind of answers I get... Thanks.