class Array
Public Instance Methods
/(len)
click to toggle source
# File lib/shoes/manual.rb, line 4 def /(len) a = [] each_with_index do |x, i| a << [] if i % len == 0 a.last << x end a end
dark?()
click to toggle source
# File lib/shoes/manual/app.rb, line 8 def dark? r, g, b = self r + g + b < 0x55 * 3 end
light?()
click to toggle source
# File lib/shoes/manual/app.rb, line 13 def light? r, g, b = self r + g + b > 0xAA * 3 end