第29340题 单选题
以下关于C++循环遍历数组的代码片段中,写法正确且符合边界优化要求的是?

已知C++数组int scores[] = {90, 85, 78, 92, 88};,需要遍历该数组并输出每个元素,要求避免数组越界且尽可能优化循环性能。

{{ option.label }}
子题{{ index + 1 }} {{ child.type_label }}
{{ option.label }}
✓ 正确 ◐ 部分正确 ✗ 错误
程序运行统计
暂无判题统计
提交{{ questionInfo.stats ? questionInfo.stats.submit_count : 0 }}次 正确率{{ statsAccuracy }}%
答案解析