implemented tournamentt selection