-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathfind.cpp
51 lines (48 loc) · 869 Bytes
/
find.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
#include <map>
#include "includes/map.hpp"
int main ()
{
CT::map<int,int> mymap;
CT::map<int, int> mymap1;
mymap[1]=101;
mymap[2]=202;
mymap[3]=302;
mymap[4]=101;
mymap[5]=202;
mymap[6]=302;
mymap[7]=101;
mymap[8]=202;
mymap[9]=302;
mymap[10]=302;
std::cout << "mymap.size() is " << mymap.size() << '\n';
mymap.erase(10);
mymap.erase(4);
mymap.erase(1);
mymap.erase(2);
mymap.erase(3);
mymap.erase(5);
mymap.erase(6);
mymap.erase(7);
mymap.erase(8);
mymap.erase(9);
mymap.erase(1);
mymap.erase(0);
mymap.erase(0);
mymap.erase(0);
mymap.erase(0);
mymap.erase(0);
mymap.erase(0);
mymap[1]=101;
mymap[2]=202;
mymap[3]=302;
mymap[4]=101;
mymap[5]=202;
mymap[6]=302;
mymap[7]=101;
mymap[8]=202;
mymap[9]=302;
mymap[10]=302;
mymap.erase(546654654);
std::cout << mymap.size() << std::endl;
return 0;
}