Home   Manual   Type Index   Symbol Index   Topics Index

std::bin

returns a string consisting of binary digits

Parameters

val
size (optional; default value: undefined)

Description

The first argument must be a positive integer number. The optional second argument specifies the minimum length of the string to be returned. If there are less bits then specified by the size then the string is left-padded with '0'-characters.

See also

std::hex   returns a string consisting of hexadecimal digits
std::oct   returns a string consisting of octal digits
std::to_string   returns a human readable presentation of the object

Topics

Math
Strings