classInteger# Check whether the integer is evenly divisible by the argument.defmultiple_of?(number)self%number==0end# Is the integer a multiple of 2?defeven?multiple_of?2endifRUBY_VERSION<'1.9'# Is the integer not a multiple of 2?defodd?!even?endifRUBY_VERSION<'1.9'end