| Algorithm 2: Mating Selection |
| Input: |
| Output: |
| 1: |
| 2: if or then |
| 3: return |
| 4: else if or then |
| 5: return |
| 6:else if then |
| 7: return |
| 8: else if then |
| 9: return |
| 10: else if then |
| 11: return |
| 12: else |
| 13: return |
| 14: end if |