I have a map which I have declared as follows:

```
map<int, bool> index;

```

and I insert values into the map as:

```
int x; cin>>x;
index[x]=true;

```

However,

`cout<<index[y]; // for any number y not in`index`gives me 0`

1. As I get the value `0` when I check for a key which is not present in the map, how can I reliably find out if a key is present in the map or not?
2. I'm using a map for trying to find out if two sets are disjoint or not, and for the same I am using a map, and two vectors to store the input. Is this shabby in any way? Some other data structure I should be using?