Post Top Ad

Your Ad Spot

Pages

Wednesday, 27 May 2020

Find Minimum element in array without shorted



public static void  Find_Min_Value(int [] arr,int n)
{
int min=arr[0];
for(int i=0;i<n;i++)
{
if(arr[i]<min)
{
   min=arr[i];
}
}
   System.out.println("MIn value is"+min);
}

No comments:

Post a Comment

Post Top Ad

Your Ad Spot

Pages