From aac97307e91db3086ee3e53c8a7052cdd99814e2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Maximilian=20Ke=C3=9Fler?= Date: Sat, 16 Apr 2022 11:49:45 +0200 Subject: [PATCH] add test in main method --- main.cpp | 9 +++++++++ segment_tree.cpp | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/main.cpp b/main.cpp index 328a890..23dad52 100644 --- a/main.cpp +++ b/main.cpp @@ -1,5 +1,14 @@ +#include +#include +#include +#include "areas.h" int main() { + srand(987192345); + std::vector inst1 = get_random_instance(10,100); + Unit area = get_area_union(inst1); + std::cout << "Area is " << area << "." << std::endl; + assert(area == 6559); return 0; } \ No newline at end of file diff --git a/segment_tree.cpp b/segment_tree.cpp index f454945..6d89a67 100644 --- a/segment_tree.cpp +++ b/segment_tree.cpp @@ -1,7 +1,7 @@ // // Created by maximilian on 16.04.22. // -#include +#include #include #include "segment_tree.h"