Sha256: c0281dbb7f72391bf6ec0a630bd84402b798f24f7ccb3bea7671a2e3add0886a
Contents?: true
Size: 443 Bytes
Versions: 396
Compression:
Stored size: 443 Bytes
Contents
local bob = {} local function shouting(say) return string.upper(say) == say end local function nothing(say) return say == nil or string.len(say) == 0 end local function question(say) return string.sub(say, -1) == '?' end function bob.hey( say ) if nothing(say) then return 'Fine, be that way.' end if shouting(say) then return "Whoa, chill out!" end if question(say) then return "Sure" end return "Whatever" end return bob
Version data entries
396 entries across 396 versions & 1 rubygems