summaryrefslogtreecommitdiff
path: root/9p25.cpp
diff options
context:
space:
mode:
authorOskar <[email protected]>2024-10-15 17:05:33 +0200
committerOskar <[email protected]>2024-10-15 17:05:33 +0200
commit7db4642f463244fdbacd2b20f261398c9de38fd9 (patch)
treea6f79131c824e489518749b17b7f4e452046e36b /9p25.cpp
parent428d857359b5d8b639ca41b03ca8fc8b3d143a50 (diff)
more
Diffstat (limited to '9p25.cpp')
-rw-r--r--9p25.cpp31
1 files changed, 31 insertions, 0 deletions
diff --git a/9p25.cpp b/9p25.cpp
new file mode 100644
index 0000000..0a14d6c
--- /dev/null
+++ b/9p25.cpp
@@ -0,0 +1,31 @@
+#include <iostream>
+#include <vector>
+
+/*
+ *
+ * 9.25
+ *
+ *
+ */
+
+int main () {
+
+ std::vector<int> slist;
+ auto elem1 = slist.begin();
+ auto elem2 = slist.end();
+ auto elem1end = slist.end();
+ auto elem2end = slist.end();
+ // All iterators above are the same
+ // And no, nothing happens.
+ if(elem1 == elem2) {
+ std::cout << "elem1 == elem2" << std::endl;
+ elem1 = slist.erase(elem1, elem2);
+ }
+
+ if(elem1end == elem2end) {
+ std::cout << "elem1end == elem2end" << std::endl;
+ elem1end = slist.erase(elem1end, elem2end);
+ }
+
+ return 0;
+}