-
-
Save jparrish62/dfd6008c49b06a431a03582aeaac0f78 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 User | |
def initialize(vote) | |
@vote = vote | |
@c = [] | |
@d = [] | |
end | |
def count | |
@c << @vote | |
votes = @c.length | |
if votes < 5 | |
puts "not enough" | |
puts "#{votes}" | |
puts "#{@c}" | |
else | |
puts "Thats it" | |
puts "#{votes}" | |
puts "#{@c}" | |
end | |
end | |
end | |
tim = User.new("8") | |
tim.count | |
jon = User.new("5") | |
jon.count |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment