diff --git a/histogram.cpp b/histogram.cpp index 4b8b614..ae048fb 100644 --- a/histogram.cpp +++ b/histogram.cpp @@ -1,5 +1,4 @@ #include "histogram.h" - void find_minmax(vector vec, double& min, double& max) { min = vec[0]; max = vec[0]; @@ -13,7 +12,6 @@ void find_minmax(vector vec, double& min, double& max) { } } } - vector make_histogram(size_t number, vector vec) { vector bins(number); double mn, mx; diff --git a/histogram_internal.h b/histogram_internal.h new file mode 100644 index 0000000..819c07f --- /dev/null +++ b/histogram_internal.h @@ -0,0 +1 @@ +void find_minmax(std::vector vec, double& min, double& max); diff --git a/main.cpp b/main.cpp index f34eb01..af1c552 100644 --- a/main.cpp +++ b/main.cpp @@ -1,11 +1,9 @@ #include "histogram.h" #include "text.h" - struct Input { vector vec; size_t korz{}; }; - Input input_data() { Input in; size_t n, korz; @@ -20,7 +18,6 @@ Input input_data() { cin >> in.korz; return in; } - int main() { auto in = input_data(); auto bins = make_histogram(in.korz, in.vec);