cplusplus
.com
TUTORIALS
REFERENCE
ARTICLES
FORUM
C++
Tutorials
Reference
Articles
Forum
Forum
Beginners
Windows Programming
UNIX/Linux Programming
General C++ Programming
Lounge
Jobs
Forum
General C++ Programming
dynamic bitset
dynamic bitset
Nov 29, 2013 at 12:00am UTC
hellcoder
(114)
i want to assign number of bits by a variable in bitset ? how to do that?
like
bitset<4> foo;
instead of 4 i want to use some variable and later on by user i want to assign it!
please don't suggest some boost library or any other library!
thank you!
Nov 29, 2013 at 2:45am UTC
Duthomhas
(13138)
The STL
bitset
is
not
dynamic. It is a compile-time constant size.
What you want to use instead is (alas) a
vector<bool>
.
Topic archived. No new replies allowed.