python3 key sorting
http://python3porting.com/preparing.html#keycmp-section