std::bitset::to_ullong

From Cppreference

Jump to: navigation, search
unsigned long long to_ullong() const
(C++11 feature)

Converts the contents of the bitset to an unsigned long long integer.

The first bit of the bitset corresponds to the least significant digit of the number and the last bit corresponds to the most significant digit.

Contents

[edit] Parameters

(none)

[edit] Return value

the converted integer

[edit] Exceptions

std::overflow_error if the value can not be represented in unsigned long long.

[edit] Example

[edit] See also

to_string
returns a string representation of the data
(public member function)
to_ulong
returns an unsigned long integer representation of the data
(public member function)