Push_Swap

To sort numbers using only two stacks (stack A and Stack B) with certine moves.
To run this project clone it into your machine.
cd push_swap
make
./push_swap and then any amount of numbers from your choice
PS. duplicates and any other character unless is it is number will show an Error!!!!

Moves

• pa : Push to stack A.
• pb : push to stack B.
• ra : rotrate stack A. (first element becomes last element)
• rb : rotrate stack B. (first element becomes last element)
• rr : rotate both stacks (it count as one move!!!)
• rra : reverse rotrate stack A. (last element becomes first element)
• rrb : reverse rotrate stack B. (last element becomes first element)
• rrr : reverse rotrate both stacks (it count as one move!!!)
• sa : swap the first two elements in stack A.
• sb : swap the first two elements in stack B.
• ss : swap the first two elements in both stack. (it count as one move!!!)

Objectives of this project

the challenge of this project is to sort any amount of numbers given by the user in less moves