单项选择题

score是一个整型数组,有5个元素,已经正确初始化并赋值,仔细阅读下面代码,程序的功能是(                )。
temp = score[0];
for (int index = 1;index < 5;index++) {
    if (score[index] < temp) {
        temp = score[index];
    }
} A.
求最大数 B.
求最小数 C.
找到数组最后一个元素 D.
编译出错

微信扫码免费搜题