I have a 2d array:
arr = [
["John", 17],
["John", 17],
["Abe", 14],
["Kobian", 18],
["Hony", 16],
["Mony", 19],
["John", 18],
["Hari", 15],
]
I want to see unique results and sorted alphabetically so that no same name is repeated.
If names are different and age is same then select one which is not repeated and is lesser age.
I worked a lot but didn’t found how to solve it… thanks in advance for the answers…
and to keep different ages: