Binary number with 0b : Binary number « Number « Ruby






Binary number with 0b


puts 0b100                          # => 4

 

Related examples in the same category

1.Binary bit shift left and right
2.Bit and, or
3.1 || 2 && nil