до тестов
Этот коммит содержится в:
@@ -2,15 +2,9 @@
|
||||
#include <vector>
|
||||
using namespace std;
|
||||
|
||||
void find_minmax(const vector<double>& numbers, double& min, double& max) {
|
||||
if (numbers.empty())
|
||||
{
|
||||
min = 0;
|
||||
max = 0;
|
||||
return;
|
||||
}
|
||||
static void find_minmax(const vector<double>& numbers, double& min, double& max) {
|
||||
max = numbers[0];
|
||||
min = numbers[0];
|
||||
min = numbers[1];
|
||||
for (double x : numbers) {
|
||||
if (x < min) min = x;
|
||||
else if (x > max) max = x;
|
||||
|
||||
Ссылка в новой задаче
Block a user