#include <curl/curl.h>
#include "histogram.h"
#include "text.h"
#include "svg.h"
struct Input {
    vector<double> vec;
    size_t korz{};
};
Input input_data() {
    Input in;
    size_t n, korz;

    cerr << "Number of elem ";
    cin >> n;
    in.vec.resize(n);
    for (size_t i = 0; i < n; i++)
        cin >> in.vec[i];
    cerr << "Enter bin count: ";
    cin >> in.korz;
    return in;
}
int main() {
    curl_global_init(CURL_GLOBAL_ALL);
    auto in = input_data();
    auto bins = make_histogram(in.korz, in.vec);
    show_histogram_svg(bins);
}
