private int generateNewTicketNumber() 
    {
        //TODO: this may take foreever. fix
        int generated = numberGenerator.next();
        while(purchased.containsKey(generated)){
            generated = numberGenerator.next();
        }
        return generated;
    }
private int generateNewTicketNumber() 
    {
       
        int generated = numberGenerator.next();
        while(purchased.containsKey(generated)){
            generated = numberGenerator.next();
        }
        return generated;
    }
private int generatenewticketnumber() { int generated = numbergenerator.next(); while(purchased.containskey(generated)){ generated = numbergenerator.next(); } return generated; }