るりまサーチ

最速Rubyリファレンスマニュアル検索!
10件ヒット [1-10件を表示] (0.076秒)
トップページ > クエリ:ruby[x] > 種類:インスタンスメソッド[x] > クエリ:self[x] > クエリ:@[x] > クラス:Numeric[x] > クエリ:negative?[x]

別のキーワード

  1. object yield_self
  2. _builtin yield_self
  3. _builtin self
  4. tracepoint self
  5. codeobject document_self

ライブラリ

検索結果

Numeric#negative? -> bool (18149.0)

self が 0 未満の場合に true を返します。そうでない場合に false を返します。

...
self
が 0 未満の場合に true を返します。そうでない場合に false を返します。

//emlist[例][ruby]{
-1.negative? # => true
0.negative? # => false
1.negative? # => false
//}

@
see Numeric#positive?...