33件ヒット
[1-33件を表示]
(0.228秒)
検索結果
先頭5件
-
FileTest
. # directory?(file) -> bool (14101.0) -
ファイルがディレクトリの時に真を返します。そうでない場合、ファイルが存在しない場合、あるいはシステムコールに失敗した場合などには false を返します。
...ブジェクト file が既に close されていた場合に発生します。
例:
FileTest.directory?('/etc') # => true
FileTest.directory?('/etc/passwd') # => false
f = File.open('/etc')
FileTest.directory?(f) # => true
f.close
FileTest.directory?(f) # => IOError: closed stream... -
Kernel
. # Complex(r , i = 0) -> Complex (8007.0) -
実部が r、虚部が i である Complex クラスのオブジェクトを生成します。
...ェクトを返しま
す。
//emlist[例][ruby]{
Complex('1+1i', '2+3i') # => (-2+3i)
Complex('1+1i') + Complex('2+3i') * Complex('i') # => (-2+3i)
//}
@see Complex.rect、Complex.rectangular
[注意] Complex.new、Complex.new! は 1.9 系では廃止されました。... -
Kernel
. # Complex(r , i = 0 , exception: true) -> Complex | nil (8007.0) -
実部が r、虚部が i である Complex クラスのオブジェクトを生成します。
...ェクトを返しま
す。
//emlist[例][ruby]{
Complex('1+1i', '2+3i') # => (-2+3i)
Complex('1+1i') + Complex('2+3i') * Complex('i') # => (-2+3i)
//}
@see Complex.rect、Complex.rectangular
[注意] Complex.new、Complex.new! は 1.9 系では廃止されました。... -
Kernel
. # Complex(s) -> Complex (8007.0) -
実部が r、虚部が i である Complex クラスのオブジェクトを生成します。
...ェクトを返しま
す。
//emlist[例][ruby]{
Complex('1+1i', '2+3i') # => (-2+3i)
Complex('1+1i') + Complex('2+3i') * Complex('i') # => (-2+3i)
//}
@see Complex.rect、Complex.rectangular
[注意] Complex.new、Complex.new! は 1.9 系では廃止されました。... -
Kernel
. # Complex(s , exception: true) -> Complex | nil (8007.0) -
実部が r、虚部が i である Complex クラスのオブジェクトを生成します。
...ェクトを返しま
す。
//emlist[例][ruby]{
Complex('1+1i', '2+3i') # => (-2+3i)
Complex('1+1i') + Complex('2+3i') * Complex('i') # => (-2+3i)
//}
@see Complex.rect、Complex.rectangular
[注意] Complex.new、Complex.new! は 1.9 系では廃止されました。...