Changed the getPos function. Also added an increment function for the linked list.