0
how to find minimum element in an array using Math.min() function ?
2 Answers
0
int[] a={34,76,39,56};//take any array
int min_no=a[0];
for(int i=1;i<a.length;i++)
min_no=Math.min(min_no,a[i]);
System.out.println(min_no);
0
In argument pass array name and print the function