Sha256: a765b9d4f154c370ac1f052180cf3f31363001d713261cbbd35db347880ff1c9
Contents?: true
Size: 204 Bytes
Versions: 36
Compression:
Stored size: 204 Bytes
Contents
# coding: utf-8 class Integer def kynea? return true if self == 7 a, b = to_s(2).match(/^(10+)(1+)$/).to_a[1..-1] return false if (a.nil? or b.nil?) a.length == (b.length - 1) end end
Version data entries
36 entries across 36 versions & 1 rubygems