adds votes to debates [#9]

This commit is contained in:
rgarcia
2015-07-18 18:10:19 +02:00
parent b8e41551f9
commit e006549092
5 changed files with 69 additions and 4 deletions

5
lib/numeric.rb Normal file
View File

@@ -0,0 +1,5 @@
class Numeric
def percent_of(n)
(self.to_f / n * 100).to_i
end
end