BlackBerry Interview Question

Sort a string with integers and numbers leaving integers and numbers

Interview Answer

Anonymous

Feb 18, 2016

A map of all 10 numbers and 26 characters (bucket sort). As we iterate through the array, we must note down the location of the numbers / characters. We just output from our bucket, picking the lowest from either the number or character bucket depending on if number or character.