push_swap
This repository contains the source files for the "push_swap" project of 1337 school.
The learning objectives
- use of C and use of basic algorithms, Especially looking at the complexity of these basic algorithms.
- rigor.
- learn Sorting algorithms, and their complexities.
This project will make you sort data on a stack, with a limited set of instructions, using the lowest possible number of actions. To succeed you’ll have to manipulate various types of algorithms and choose the one (of many) most appropriate solution for an optimized data sorting.
The Push_swap project is a very simple and highly effective algorithm project: data will need to be sorted. You have at your disposal a set of int values, 2 stacks and a set of instructions to manipulate both stacks.
Your goal ? Write a program in C called push_swap which calculates and displays on the standard output the smallest program using Push_swap instruction language that sorts the integer arguments received.
How to use the code
You need to download this repository to your computer, then compile and run the code.
use make
to compile the push_swap program and use ./push_swap
to run it.
use make bonus
to compile the checker program and use ./checker
to run it.
for more details read subject_en.pdf