Sum All Elements in a K-Dimensional Array
Problem
You are given a k-dimensional array object array and a list dimensions of length k, where dimensions[d] is the size of dimension d.
You may access an element only through `arr...
Example
Unlock to view complete problem details
and practice with sample input/output
Was this article helpful?
View Test Cases & Run Code requires membership
Standard Input
Execution Result:
