New algorithms: Majority Element and Pancake Sorting