From: Christian on 14 Oct 2009 20:57 so i'm trying to find the sum of the rings of an array, and return the sums starting with the innermost ring. i also have to use recursion. for example, if arr = 1 2 3 4 5 6 7 8 9 output = [5 40] i tried adding up all the numbers on the outside and then manually deleting the outside ring and then moving to the inner ring but i seem to be running into issues. I was just hoping someone could give me a hint towards another way to solve the problem. thanks, -chris
|
Pages: 1 Prev: huffman coding finding Next: PowerGUI FFT won't update waveforms |