1. Use passed compare function instead of default.
2. return value less, great or equal to 0 if a < b, a > b or a == 0 respectively
3. TypeError exceptions
Fixed function name
Coctail sort implementation.