Collection subclass: #Ticket
  instanceVariableNames: 'rep '
  classVariableNames: '' poolDictionaries: '' !

!Ticket class methods !
  
new
    ^ self new: (Set new)!

new: aSet
    "ENSURES: result is a new Ticket with the elements of aSet
                        as its set of numbers"
     ^super new initialize: aSet! !

!Ticket methods !
 
copy
    "ENSURES: result is a ticket with the same abstract value as self"
    ^ self class new: rep!

do: aBlock
    ^ rep do: aBlock!
   
initialize: aSet
    "EFFECT: this ticket's abstract value becomes the same as aSet"
    rep := Set new.
    rep addAll: aSet.! !
