Sha256: fef8bba3abd3a167dbfe460bdb17e1b4c663ce3ae5d279a77584e59747b5b2c2

Contents?: true

Size: 179 Bytes

Versions: 9

Compression:

Stored size: 179 Bytes

Contents

# encoding: utf-8

module Rubymisc
  module Integer
    def percent_of(number)
      self.to_f * 100 / number
    end
  end
end

::Integer.module_eval 'include Rubymisc::Integer'

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
rubymisc-0.2.0 lib/rubymisc/ext/integer.rb
rubymisc-0.1.0 lib/rubymisc/ext/integer.rb
rubymisc-0.0.4 lib/rubymisc/ext/integer.rb
rubymisc-0.0.3.3 lib/rubymisc/ext/integer.rb
rubymisc-0.0.3.2 lib/rubymisc/ext/integer.rb
rubymisc-0.0.3.1 lib/rubymisc/ext/integer.rb
rubymisc-0.0.3 lib/rubymisc/ext/integer.rb
rubymisc-0.0.2 lib/rubymisc/ext/integer.rb
rubymisc-0.0.1 lib/rubymisc/ext/integer.rb