diff --git a/lab03.cbp b/lab03.cbp index bd407e1..52780f4 100644 --- a/lab03.cbp +++ b/lab03.cbp @@ -31,7 +31,12 @@ <Compiler> <Add option="-Wall" /> <Add option="-fexceptions" /> + <Add directory="curl/include" /> </Compiler> + <Linker> + <Add library="libcurl.dll.a" /> + <Add directory="curl/lib" /> + </Linker> <Unit filename="histogram.cpp" /> <Unit filename="histogram.h" /> <Unit filename="histogram_internal.h" /> diff --git a/lab03.depend b/lab03.depend index d03a884..887804a 100644 --- a/lab03.depend +++ b/lab03.depend @@ -7,7 +7,7 @@ 1716797551 c:\users\lenov\desktop\lab03\histogram.h <vector> -1717518697 source:c:\users\lenov\desktop\lab03\main.cpp +1717520017 source:c:\users\lenov\desktop\lab03\main.cpp <iostream> <vector> "histogram.h" diff --git a/main.cpp b/main.cpp index 5333d37..e8d9f17 100644 --- a/main.cpp +++ b/main.cpp @@ -34,14 +34,18 @@ input_data(istream& stream, bool prompt) { return in; } -int main() +int main(int argc, char* argv[]) { + if (argc > 1) { + for (int i = 0; i < argc; i++) { + cout << "argv[" << i << "] = " << argv[i]; + } + return 0; + } curl_global_init(CURL_GLOBAL_ALL); - Input in = input_data(cin, false); - auto bins = make_histogram(in.numbers, in.bin_count); + vector<size_t> bins = make_histogram(in.numbers, in.bin_count); show_histogram_svg(bins); - return 0; }