Shell sort implemetation