You are viewing a single comment's thread. Return to all comments →
my function is as follows:
static int birthdayCakeCandles(Integer n, Integer[] ar) { int count=0; List<Integer> cardsList =Arrays.asList(ar); Integer max=Collections.max(cardsList); for(int j=0;j<cardsList.size();j++) { if(cardsList.get(j)==max) { System.out.println("TMC"); count++; } else System.out.println("BCMK"); } return count; }
but it checks the integer values only upto 127. can anyone help me out?. PS: I have attached the output of the program.
Seems like cookies are disabled on this browser, please enable them to open this website
Birthday Cake Candles
You are viewing a single comment's thread. Return to all comments →
my function is as follows: