added a little helper class to check method arguments
reimplemented sorting algorithms
cleaning up to continue