Advertisement
Guest User

Untitled

a guest
Nov 12th, 2012
160
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.24 KB | None | 0 0
  1. private static double RecursiveAverage(double[] arr, int iteration, double sum)
  2. {
  3.       if (iteration == arr.Length)
  4.             return sum/arr.Length;
  5.       sum += arr[iteration];
  6.       return RecursiveAverage(arr, iteration + 1, sum);
  7. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement