From 110481bee48bdb18f3d635cbc507aac1acc7c694 Mon Sep 17 00:00:00 2001 From: angeld55 Date: Tue, 24 May 2022 20:10:50 +0300 Subject: added shapes collection --- Sem. 13/ShapeCollection/main.cpp | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 Sem. 13/ShapeCollection/main.cpp (limited to 'Sem. 13/ShapeCollection/main.cpp') diff --git a/Sem. 13/ShapeCollection/main.cpp b/Sem. 13/ShapeCollection/main.cpp new file mode 100644 index 0000000..4b6e784 --- /dev/null +++ b/Sem. 13/ShapeCollection/main.cpp @@ -0,0 +1,18 @@ +#include +#include "ShapeCollection.h" +using namespace std; + +int main() +{ + ShapeCollection s; + + s.addCircle(3, 4, 1); + s.addTriangle(1, 2, 9, 4, 0, 0); + s.addRectangle(1, 1, 9, 9); + + std::cout << s.getIfPointInShapeByIndex(0, 3, 4.5)<< std::endl; + std::cout << s.getAreaOfFigureByIndex(2) << std::endl; + + + +} \ No newline at end of file -- cgit v1.3.1-23-gd82d