配列の最小値を見つけようとしている場合は、次のように実行できます。
int b[] = {1,3,2,5,2,3};
//min needs to have a starting value so b[0] works fine.
int min = b[0];
//This loops over the remaining elements in the array. If it finds a value smaller than the current minimum, it reassigns min to that value.
for(int i = 1; i < b.length; i++)
{
if(b[i] < min)
min = b[i];
}
//If you haven't covered for loops yet, here is how you can do it with a while.
int i = 1;
while(i < b.length)
{
if(b[i] < min)
min = b[i];
i++;
}
//b.length is just a way of getting the length of an array.