diff options
| author | mzuenni <michi.zuendorf@gmail.com> | 2023-03-28 13:25:59 +0200 |
|---|---|---|
| committer | mzuenni <michi.zuendorf@gmail.com> | 2023-03-28 13:25:59 +0200 |
| commit | fe5fa1141efeb7454c763dbd2645fb4ff04487a3 (patch) | |
| tree | f2197bb94ce80ab2fae886177dfa9b0bd11538ac /datastructures/bitset.cpp | |
| parent | 3b91d2662310aee532cc84e1447824459671767e (diff) | |
merged
Diffstat (limited to 'datastructures/bitset.cpp')
| -rw-r--r-- | datastructures/bitset.cpp | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/datastructures/bitset.cpp b/datastructures/bitset.cpp index 9f33a5b..242d821 100644 --- a/datastructures/bitset.cpp +++ b/datastructures/bitset.cpp @@ -1,7 +1,6 @@ bitset<10> bits(0b000010100); -cout << bits._Find_first() << endl; //2 -cout << bits._Find_next(2) << endl; //4 -cout << bits._Find_next(4) << endl; //10 bzw. N -bits[x] = 1; //not bits.set(x)! -bits[x] = 0; //not bits.reset(x)! -bits[x].flip(); //not bits.flip(x)! +bits._Find_first(); //2 +bits._Find_next(2); //4 +bits._Find_next(4); //10 bzw. N +bits[x] = 1; //not bits.set(x) or bits.reset(x)! +bits[x].flip(); //not bits.flip(x)! |
