Ruby 2.3.0 リファレンスマニュアル > ライブラリ一覧 > 組み込みライブラリ > Integerクラス > &

instance method Integer#&

self & other -> Integer[permalink][rdoc]

ビット二項演算子。論理積を計算します。

[PARAM] other:
数値

1 & 1  # => 1
2 & 3  # => 2