set [C++ Reference]
Keywords: stl,bitset,set
Date: 2010-03-02T07:29:04-0800

[[set]]
C++ Reference
Translations of this page?:

- en
- br-pt
- cn
- cz
- de
- es
- fr
- it
- jp
- nl
- pl
- ro
- ru
- sk
- tr
- tw

## set

Syntax:

        #include <bitset>
        bitset<N>& set();
        bitset<N>& set( size_t pos, bool val=true );

The set() function sets all of the bits in the bitset, and returns the bitset.

If pos is specified, then only the bit at position pos is set. pos can be in the range 0 to N-1.

If val is specified, then the bit is set or reset depending on the value of val.

Edit this page • Old revisions
• • • Login • Index • Recent changes • RSS • cc •