This question already has an answer here:
How should we name this compound by IUPAC system? Is it
2,3-dimethylcyclohexene (or) 1,6-dimethylcyclohexene?
In the first case locant position adds to 2+3 = 5, while in second it is 1+6 = 7. However, in second case, first substituent gets lower position, i.e., 1 , while in first case it gets 2.