因为正巧助人为乐,又是第一次编写的C++程序,颇具纪念意义,所以发上来了。
如题,东西我大概在注释里写的比较详细了
#includeusing namespace std; int main(){ int personCount; //*人数计数 double tempArr[5]; //*用于储存单个人的平均数 double biggestAverage; //*最大的个人平均数 cin >> personCount; double personsAverage[100000]; //*每个人的平均数 for(int i = 0;i > tempArr[k]; sumEnding += tempArr[k]; if(k == 0){ tempMax = tempArr[k]; tempMin = tempArr[k]; } if(tempArr[k]>tempMax){ //*当当前录入数据大于记录到的最大值 tempMax = tempArr[k]; }if(tempArr[k] biggestAverage){ biggestAverage = personsAverage[i]; } } //*cout << personsAverage[0] << ";" <



