You are viewing a single comment's thread. Return to all comments →
public static void plusMinus(List arr) { // Write your code here float zeroCount =0; float postiveCount=0; float negativeCount=0; for(int i=0;i0){ postiveCount++; } else { negativeCount++; } } System.out.println((postiveCount/arr.size())); System.out.println(negativeCount/arr.size()); System.out.println(zeroCount/arr.size()); }
Seems like cookies are disabled on this browser, please enable them to open this website
Plus Minus
You are viewing a single comment's thread. Return to all comments →
public static void plusMinus(List arr) { // Write your code here float zeroCount =0; float postiveCount=0; float negativeCount=0; for(int i=0;i0){ postiveCount++; } else { negativeCount++; } } System.out.println((postiveCount/arr.size())); System.out.println(negativeCount/arr.size()); System.out.println(zeroCount/arr.size()); }