Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //per richiamare il metodo: somma(array, 0, 0)
- //E comunque sei una schiappa!
- public static int somma(int[] arr, int totale, int i){
- if (i< arr.length){
- totale = arr[i]+totale;
- i++;
- return somma(arr, totale, i);
- }
- else{
- return totale;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement