diff options
Diffstat (limited to 'labs/include/intvector.hpp')
-rw-r--r-- | labs/include/intvector.hpp | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/labs/include/intvector.hpp b/labs/include/intvector.hpp new file mode 100644 index 0000000..f5f0912 --- /dev/null +++ b/labs/include/intvector.hpp @@ -0,0 +1,29 @@ +#ifndef INTVECTOR_HPP +#define INTVECTOR_HPP + +#include <cmath> + +class intvector { +public: + intvector(); + intvector(const intvector& input_vector); + intvector(int size); + ~intvector(); + + intvector& operator=(const intvector& input_vector); + int& operator[](const int& index); + const int& operator[](const int& index) const; + + void push_back(int i); + + int& at(const int& i); + int size() const; + int capacity() const; + int find(const int& i) const; +private: + int* vector_pointer; + int vector_size; + int vector_capacity; +}; + +#endif |