small refactoring, added quick and insertion sorts & tests