Added sort function
Merge pull request #64 from realcnbs/sort-function

#34 Added sort function