Question whether a variable is type_float

type:float?($variable) : BOOL

type:float?(2.0)     #=> true
type:float?(2.2)     #=> true
type:float?(-2.2)    #=> true
type:float?(0)       #=> false
type:float?(0.0)     #=> true
type:float?(2)       #=> false 
type:float?(true)    #=> false
type:float?('2')     #=> false
type:float?('hi')    #=> false

Copyright ©2013-2022 SunSed®. All rights reserved.