Is there a way that I can sort an array based on an alphabetical sort that I did to another array? The practical use to this would be trying to associate an array with usernames to an array that contains those usernames' names. I have two separate lists containing this information and I need to alphabetically sort the users based on their name, but I need to access their username too. So in order to do this I'm trying to have both pieces of data within the table view cell and just show the name and hide the username.
I can't reverse sort the array containing the names to the usernames because if two people had the same names this would cause many problems.
I tried using a NSMutableDictionary but this didn't work. Any help would be extremely helpful!