implemented won, code working