code: отображение гистограммы вынесено в функцию show_histogram_text

master
Artem 1 год назад
Родитель 2bb0cb3af1
Сommit 0e04d0dc01

@ -73,13 +73,7 @@ vector<size_t> make_histogram(vector<double>& numbers, size_t bin_count){
return bins; return bins;
} }
void show_histogram_text(vector<size_t>& bins){
int
main()
{
auto in = input_data();
auto bins = make_histogram(in.numbers, in.bin_count);
size_t max_count = 0; size_t max_count = 0;
for (size_t x: bins) { for (size_t x: bins) {
@ -129,5 +123,13 @@ main()
} }
} }
}
int
main()
{
auto in = input_data();
auto bins = make_histogram(in.numbers, in.bin_count);
show_histogram_text(bins);
return 0; return 0;
} }

Загрузка…
Отмена
Сохранить