typedef struct { int hash[1000001]; } MyHashSet; /** Initialize your data structure here. */ MyHashSet* myHashSetCreate() { MyHashSet* obj=(MyHashSet*)calloc(sizeof(MyHashSet),1); return obj; } void myHashSetAdd(MyHashSet* obj, int key) { obj->hash[key]=1; } void myHashSetRemove(MyHashSet* obj, int key) { obj->hash[key]=0; } /** Returns true if this set contains the specified element */ bool myHashSetContains(MyHashSet* obj, int key) { return obj->hash[key]; } void myHashSetFree(MyHashSet* obj) { free(obj); }