From f0516d3303615f72dd525fad7ffcb182824f42e7 Mon Sep 17 00:00:00 2001 From: Syndamia Date: Mon, 2 May 2022 20:50:19 +0300 Subject: Autocommit at 02.05.2022 @ 20:50 --- src/.!lazygit.swo | Bin 24576 -> 24576 bytes src/List/List.cpp | 5 +++++ src/List/List.h | 2 +- 3 files changed, 6 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/.!lazygit.swo b/src/.!lazygit.swo index 3145500..7fb9838 100644 Binary files a/src/.!lazygit.swo and b/src/.!lazygit.swo differ diff --git a/src/List/List.cpp b/src/List/List.cpp index 1f3540f..f65cbba 100644 --- a/src/List/List.cpp +++ b/src/List/List.cpp @@ -41,6 +41,11 @@ void List::add(const T& element) { elements[count++] = element; } +template +bool List::insertAt(const T& element) { + +} + template bool List::removeAt(unsigned index) { if (index >= count) return false; diff --git a/src/List/List.h b/src/List/List.h index d2e4280..1068bb7 100644 --- a/src/List/List.h +++ b/src/List/List.h @@ -17,7 +17,7 @@ class List { public: List(const T* elements, unsigned elementsCount); void add(const T& element); - bool insertAt(const T& element); + bool insertAt(const T& element, unsigned index); bool removeAt(unsigned index); T& operator[](unsigned index); const T& operator[](unsigned index) const; -- cgit v1.3.1-26-gb76a