-
-
Save denstark/fa189e5de7d65a700a36 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class DiceSet | |
@diceset = Array.new | |
def initialize(num=1) | |
(1..num).each do |i| | |
addRoll | |
end | |
end | |
def addRoll | |
@diceset << rand(1..6) | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment