Skip to content

Conversation

@MinyazevR
Copy link
Owner

No description provided.

Copy link

@yurii-litvinov yurii-litvinov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Комментарии к коммитам ужасны :) Надо писать что-то содержательное, типа "Added solution for the first task" или что-то такое

int arrayOFNumber[10] = {199, 36, 123, 1, 2, 6, 8, 9, 7, 10};
int sum[10] = {0};
return largestSun(arrayOFNumber, sum, 10) == 0;

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change

{
int arrayOFNumber[10] = {199, 36, 123, 1, 2, 6, 8, 9, 7, 10};
int sum[10] = {0};
return largestSun(arrayOFNumber, sum, 10) == 0;

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

largestSun пока ещё не объявлен, должно быть предупреждение компилятора


}

int largestSun(int *array,int* sum,int numberOfElements)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"Самое большое Солнце"? :) Должно быть largestSum, наверное


}

int largestSun(int *array,int* sum,int numberOfElements)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
int largestSun(int *array,int* sum,int numberOfElements)
int largestSun(int *array, int* sum, int numberOfElements)

}
}
return j;
}

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
}
}

for (int i = 0; i < numberOfElement - 1; i++)
{
int count = 0;
int temporary = arrayOfNumber[i];

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Кажется, что temporary всегда равна arrayOfNumber[count], так что её можно явно не хранить было

@@ -0,0 +1,23 @@
#include "choiseSort.h"

void sortChoise(int* arrayOfNumber, int numberOfElement)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
void sortChoise(int* arrayOfNumber, int numberOfElement)
void sortChoice(int* arrayOfNumber, int numberOfElement)

int main()
{
setlocale(LC_ALL, "rus");
if (!testSort�hoice())

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

О, русская буква "С" в Choice. Это такое пожелание тем, кто будет сопровождать код, удачно разобраться с ошибками компиляции :)

}
}
return true;
}

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
}
}

@@ -0,0 +1,3 @@
#pragma once

void sortChoise(int* arrayOfNumber, int numberOfElement);

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Тоже надо было бы комментарии

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants