class Basic101::IntFunction

Public Instance Methods

call(runtime, args) click to toggle source
# File lib/basic101/int_function.rb, line 11
def call(runtime, args)
  check_args args, [BasicNumeric]
  value = args.first.eval(runtime)
  value.to_float.floor
end
name() click to toggle source
# File lib/basic101/int_function.rb, line 7
def name
  'INT'
end