|
|
@ -42,13 +42,24 @@ input_data(istream& stream, bool prompt) {
|
|
|
|
return in;
|
|
|
|
return in;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
int main()
|
|
|
|
int main(int argc, char* argv[])
|
|
|
|
{
|
|
|
|
{
|
|
|
|
curl_global_init(CURL_GLOBAL_ALL);
|
|
|
|
if (argc > 1) {
|
|
|
|
|
|
|
|
CURL* curl = curl_easy_init();
|
|
|
|
|
|
|
|
if(curl) {
|
|
|
|
|
|
|
|
CURLcode res;
|
|
|
|
|
|
|
|
curl_easy_setopt(curl, CURLOPT_URL, argv[1]);
|
|
|
|
|
|
|
|
res = curl_easy_perform(curl);
|
|
|
|
|
|
|
|
curl_easy_cleanup(curl);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
//curl_global_init(CURL_GLOBAL_ALL);
|
|
|
|
bool prompt = true;
|
|
|
|
bool prompt = true;
|
|
|
|
auto in = input_data(cin, prompt);
|
|
|
|
auto in = input_data(cin, prompt);
|
|
|
|
vector<size_t> bins = make_histogram(in.numbers, in.bin_count, in.number_count, in.max_count);
|
|
|
|
vector<size_t> bins = make_histogram(in.numbers, in.bin_count, in.number_count, in.max_count);
|
|
|
|
show_histogram_svg(bins);
|
|
|
|
show_histogram_svg(bins);
|
|
|
|
return 0;
|
|
|
|
return 0;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|