bsort idea finished but not yet compiled and debugged