fork download
  1. Card = Struct.new(:face, :suit, :value)
  2. deck = []
  3. deck << Card.new("Queen", "Spade", 12)
  4. puts deck[0].face
  5. puts deck[0].suit
  6. puts deck[0].value
Success #stdin #stdout 0.01s 7408KB
stdin
Standard input is empty
stdout
Queen
Spade
12