Skip to content

Latest commit

 

History

24 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

📊​ Push Swap

42_pushswap

Overview

Push Swap is a project by 42 School, whose goal is to develop a program capable of sorting a stack of integers in a minimum number of moves, using a limited set of operations. It focuses on the design and implementation of sorting algorithms, as well as the analysis of their complexity and optimization.

Usage

make bonus
# Compile the executable 'checker'

ARG="4 67 3 87 23"; ./push_swap $ARG | ./checker $ARG
# ARG: list of numbers to sort
# Returns 'OK' if sorting was successful
# Returns 'KO' if sorting failed
# Returns 'Error' if input is invalid (non-numeric character, duplicate)

make runtest ELM=100 RUN=50 MAX=700
# ELM: number of elements to sort
# RUN: number of tests to run
# MAX: maximum number of moves allowed
# The script then displays the results of the various tests (average, minimum, maximum, success rate)

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages