Class for Selection Sort - Generic type