Generation

generate functionSat, 12 Nov 2022

find the greatest number from an arraylist

public int findGreatestNumber(list) { int max = 0; for (int i = 0; i < list.length; i++) { if (list[i] > max) { max = list[i]; } } return max; }

Want to kickstart your project?Use the new AI Studio to create your code