Class: Lambda
- Inherits:
-
Object
- Object
- Lambda
- Defined in:
- lib/lib/lambda.rb
Class Method Summary collapse
Class Method Details
.array(it) ⇒ Object
6 7 8 9 10 11 12 13 14 |
# File 'lib/lib/lambda.rb', line 6 def Lambda.array(it) a = Array.new _it = Rb::RubyIterator.new(it) while(_it.has_next) do i = _it._next a.push(i) end a end |
.has(it, elt) ⇒ Object
26 27 28 29 30 31 32 33 |
# File 'lib/lib/lambda.rb', line 26 def Lambda.has(it,elt) _it = Rb::RubyIterator.new(it) while(_it.has_next) do x = _it._next return true if x == elt end false end |