Aktualizovat „du5/program.c“

This commit is contained in:
Bohdan Yanchyk 2020-04-09 21:12:56 +00:00
parent fffae6b518
commit 2e4df70c5d

View File

@ -53,7 +53,7 @@ int main(){
int res_strcmp=0; int res_strcmp=0;
int idex = 0; int idex = 0;
for(int i =0;i<c;i++){ for(int i =0;i<c;i++){
for(int j = i;j<c;j++){ for(int j = i+1;j<c;j++){
res_strcmp = strcmp(PersonList[i].name,PersonList[j].name); res_strcmp = strcmp(PersonList[i].name,PersonList[j].name);
if(res_strcmp==0){ if(res_strcmp==0){
PersonList[i-idex].score += PersonList[i+1].score; PersonList[i-idex].score += PersonList[i+1].score;