The most efficient sorting algorithm, wouldn't be a traditional one.
Since you are sorting based on criteria such as birth year and zodiac sign, I would do a "stack sort" (I just made that up).
It would work this way.
Create a data structure for each possible sorted value. Let's use birth year for example. In birth year, there are only going to be ~100 different values that it could be.
- Declare a data structure for each possible value for Birth year (100 pointer arrays, one for each year)
- Loop through each record, and place a pointer to the record in that array.
When you're done looping through each record, you've now got 100 arrays, each filled with records that have that particular birth year. The great part about this is that you've done it in O(n) time, so it's much faster than any other sorting algorithm. This also works for zodiac signs etc...
Think outside of the box. This approach is very useful when sorting a large dataset (n) with possible values (m), where m << n.
O(n*n)average running time, which isn't going to cut it for 100M items. Then heapsort and quicksort are ruled out because they are not stable (no such thing as "kinda" unstable). That only leaves merge. Well done! :)