Implementation of Insertion Sort on array