Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- D:Temp>type vectorbool.cpp
- #include <iostream>
- #include <vector>
- using namespace std;
- int main() {
- vector<bool> vb(10);
- vb[5] = true;
- for (vector<bool>::const_iterator ci = vb.begin(); ci != vb.end(); ++ci) {
- cout << *ci << endl;
- }
- }
- D:Temp>cl /nologo /W4 /EHsc vectorbool.cpp
- vectorbool.cpp
- D:Temp>vectorbool.exe
- 0
- 0
- 0
- 0
- 0
- 1
- 0
- 0
- 0
- 0
- if (mapObj.count(item) != 0)
- {
- // item exists
- }
Add Comment
Please, Sign In to add comment