добавлены аргументы
Этот коммит содержится в:
7
main.cpp
7
main.cpp
@@ -26,7 +26,6 @@ Input input_data(istream& in, bool prompt) {
|
|||||||
cin >> inp.numbers[i];
|
cin >> inp.numbers[i];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
if (prompt) {
|
if (prompt) {
|
||||||
cerr << "Enter bin count: ";
|
cerr << "Enter bin count: ";
|
||||||
}
|
}
|
||||||
@@ -34,8 +33,12 @@ Input input_data(istream& in, bool prompt) {
|
|||||||
return inp;
|
return inp;
|
||||||
}
|
}
|
||||||
|
|
||||||
int main() {
|
int main(int argc, char* argv[]) {
|
||||||
curl_global_init(CURL_GLOBAL_ALL);
|
curl_global_init(CURL_GLOBAL_ALL);
|
||||||
|
if (argc > 1){
|
||||||
|
cerr << "argv[0] = " << argv[0] << "argc = " << argc;
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
auto in = input_data(cin, true);
|
auto in = input_data(cin, true);
|
||||||
auto bins = make_histogram(in.numbers, in.bin_count);
|
auto bins = make_histogram(in.numbers, in.bin_count);
|
||||||
show_histogram_svg(bins);
|
show_histogram_svg(bins);
|
||||||
|
|||||||
Ссылка в новой задаче
Block a user