From 2341494fc24a5bca5f14460c480409bbffe45483 Mon Sep 17 00:00:00 2001 From: "Igor (ZharkovIG)" Date: Sun, 20 Oct 2024 15:01:33 +0300 Subject: [PATCH] =?UTF-8?q?code:=20=D0=94=D0=BE=D0=B1=D0=B0=D0=B2=D0=BB?= =?UTF-8?q?=D0=B5=D0=BD=20=D0=BF=D0=B0=D1=80=D0=B0=D0=BC=D0=B5=D1=82=D1=80?= =?UTF-8?q?=20cin=20=D0=B2=20input=5Fdata?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lab1.cbp | 17 ++++++++++++++--- main.cpp | 4 ++-- unittest.cbp | 3 +++ 3 files changed, 19 insertions(+), 5 deletions(-) diff --git a/lab1.cbp b/lab1.cbp index be1f46d..0b5eff7 100644 --- a/lab1.cbp +++ b/lab1.cbp @@ -32,11 +32,22 @@ + + + + + + + + + + - - - diff --git a/main.cpp b/main.cpp index efe800b..c72f2cf 100644 --- a/main.cpp +++ b/main.cpp @@ -10,7 +10,7 @@ struct Input { }; Input -input_data(){ +input_data(istream& in){ size_t number_count; cerr << "Enter number_count: "; @@ -32,7 +32,7 @@ input_data(){ int main() { - auto in = input_data(); + auto in = input_data(cin); auto bins = make_histogram(in.numbers, in.bin_count); show_histogram_svg(bins); return 0; diff --git a/unittest.cbp b/unittest.cbp index 7f9621b..534f497 100644 --- a/unittest.cbp +++ b/unittest.cbp @@ -31,6 +31,9 @@ + + +