From 77b344e13eae4b4439f96a8d062151da03bf8263 Mon Sep 17 00:00:00 2001 From: Oskar Date: Fri, 1 Nov 2024 10:44:53 +0100 Subject: been a while, took a break i guess --- 9p38.cpp | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 9p38.cpp (limited to '9p38.cpp') diff --git a/9p38.cpp b/9p38.cpp new file mode 100644 index 0000000..c396afa --- /dev/null +++ b/9p38.cpp @@ -0,0 +1,24 @@ +#include +#include + +/* + * + * 9.38 + * + * + */ + +int main () { + + std::vector vi = {1,2,3,4,5,6,7,8,9,10,11,12,13,14,15}; + std::vector vi2(100); + std::vector vi3; + std::cout << vi.size() << " " << vi.capacity() << std::endl; + std::cout << vi2.size() << " " << vi2.capacity() << std::endl; + for(size_t i = 0 ; i != 1025 ; ++i) { + vi3.push_back(0); + std::cout << vi3.size() << " " << vi3.capacity() << std::endl; + } + + return 0; +} -- cgit v1.2.3