Go Fish/Ruby: Difference between revisions
Content added Content deleted
(Created page with '{{collection|Go Fish}}Category:Ruby <lang ruby>class Card RANKS = %w(2 3 4 5 6 7 8 9 10 J Q K A) SUITS = %w(C D H S) def initialize(rank, suit) @rank = rank @…') |
mNo edit summary |
||
Line 9: | Line 9: | ||
@suit = suit |
@suit = suit |
||
end |
end |
||
attr_reader :rank, :suit |
|||
def <=>(other) |
def <=>(other) |