Do implementation for Select Sort.