diff --git a/.vscode/launch.json b/.vscode/launch.json new file mode 100644 index 0000000..655f330 --- /dev/null +++ b/.vscode/launch.json @@ -0,0 +1,7 @@ +{ + // Используйте IntelliSense, чтобы узнать о возможных атрибутах. + // Наведите указатель мыши, чтобы просмотреть описания существующих атрибутов. + // Для получения дополнительной информации посетите: https://go.microsoft.com/fwlink/?linkid=830387 + "version": "0.2.0", + "configurations": [] +} \ No newline at end of file diff --git a/.vscode/tasks.json b/.vscode/tasks.json new file mode 100644 index 0000000..d22751d --- /dev/null +++ b/.vscode/tasks.json @@ -0,0 +1,29 @@ +{ + "tasks": [ + { + "type": "cppbuild", + "label": "C/C++: clang++ сборка активного файла", + "command": "/usr/bin/clang++", + "args": [ + "-fcolor-diagnostics", + "-fansi-escape-codes", + "-g", + "${file}", + "-o", + "${fileDirname}/${fileBasenameNoExtension}" + ], + "options": { + "cwd": "${fileDirname}" + }, + "problemMatcher": [ + "$gcc" + ], + "group": { + "kind": "build", + "isDefault": true + }, + "detail": "Задача создана отладчиком." + } + ], + "version": "2.0.0" +} \ No newline at end of file diff --git a/project/exit file.html b/project/exit file.html new file mode 100644 index 0000000..6586768 --- /dev/null +++ b/project/exit file.html @@ -0,0 +1,3 @@ +<?xml version='1.0' encoding='UTF-8'?> +<svg width='400' height='300' viewBox='0 0 400 300' xmlns='http://www.w3.org/2000/svg'> +<rect x='0' y='0' width='0' height='30' stroke='white' fill='#ffffff' /><text x='360' y='20'>1</text><rect x='0' y='0' width='350' height='30' stroke='red' fill='#aaffaa' /><rect x='0' y='30' width='0' height='30' stroke='white' fill='#ffffff' /><text x='360' y='50'>1</text><rect x='0' y='30' width='350' height='30' stroke='red' fill='#aaffaa' /><rect x='0' y='60' width='0' height='30' stroke='white' fill='#ffffff' /><text x='360' y='80'>1</text><rect x='0' y='60' width='350' height='30' stroke='red' fill='#aaffaa' /></svg> diff --git a/project/histogram_internal.h b/project/histogram_internal.h new file mode 100644 index 0000000..ad98f9c --- /dev/null +++ b/project/histogram_internal.h @@ -0,0 +1,6 @@ +#ifndef HISTOGRAM_INTERNAL_H_INCLUDED +#define HISTOGRAM_INTERNAL_H_INCLUDED +#include <vector> + +void find_minmax(std::vector<double> numbers, double &min, double &max); +#endif // HISTOGRAM_INTERNAL_H_INCLUDED \ No newline at end of file diff --git a/project/main b/project/main new file mode 100755 index 0000000..de25e97 Binary files /dev/null and b/project/main differ diff --git a/project/main.cpp b/project/main.cpp index 627b7d0..a78901a 100644 --- a/project/main.cpp +++ b/project/main.cpp @@ -1,18 +1,18 @@ #include <iostream> #include <vector> -#include "histogram.h" -#include "text.h" -#include "svg.h" +#include "histogram.cpp" +#include "text.cpp" +#include "svg.cpp" using namespace std; struct Input { vector<double> numbers; - size_t bin_count{}; + size_t bin_count; }; Input input_data(){ size_t number_count; - cerr << "Enter number count: "; + cerr << "Enter number count "; cin >> number_count; Input in; in.numbers.resize(number_count); @@ -20,7 +20,7 @@ input_data(){ { cin >> in.numbers[i]; } - cerr << "Enter bin count: "; + cerr << "Enter bin count "; cin >> in.bin_count; return in; } diff --git a/project/main.dSYM/Contents/Info.plist b/project/main.dSYM/Contents/Info.plist new file mode 100644 index 0000000..fe7fecd --- /dev/null +++ b/project/main.dSYM/Contents/Info.plist @@ -0,0 +1,20 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> +<plist version="1.0"> + <dict> + <key>CFBundleDevelopmentRegion</key> + <string>English</string> + <key>CFBundleIdentifier</key> + <string>com.apple.xcode.dsym.main</string> + <key>CFBundleInfoDictionaryVersion</key> + <string>6.0</string> + <key>CFBundlePackageType</key> + <string>dSYM</string> + <key>CFBundleSignature</key> + <string>????</string> + <key>CFBundleShortVersionString</key> + <string>1.0</string> + <key>CFBundleVersion</key> + <string>1</string> + </dict> +</plist> diff --git a/project/main.dSYM/Contents/Resources/DWARF/main b/project/main.dSYM/Contents/Resources/DWARF/main new file mode 100644 index 0000000..072be56 Binary files /dev/null and b/project/main.dSYM/Contents/Resources/DWARF/main differ diff --git a/project/svg.cpp b/project/svg.cpp index 53e46d9..d843ed9 100644 --- a/project/svg.cpp +++ b/project/svg.cpp @@ -1,6 +1,5 @@ #include <math.h> #include <iostream> -#include <conio.h> #include <vector> #include <string> #include "svg.h"