mirror of
https://github.com/DavidGailleton/42-Push_Swap.git
synced 2026-11-01 08:12:03 +01:00
finish the parsing solve the problem with 2 arg
This commit is contained in:
1 parent
00e01ed1f9
commit
0df082065e
4 files changed
+18
-3
No files matched your search
+10
-3
@@ -26,11 +26,18 @@ void medium(t_stacks *piles)
|
||||
{
|
||||
t_tab *buckets;
|
||||
int range;
|
||||
int len;
|
||||
|
||||
piles->algo = 2;
|
||||
range = range_bucket(piles->a);
|
||||
buckets = get_tabs(piles->a, range);
|
||||
bucket_algo(piles, buckets, range);
|
||||
len = stack_a_len(piles);
|
||||
if (len == 2)
|
||||
sort_two(piles);
|
||||
else
|
||||
{
|
||||
range = range_bucket(piles->a);
|
||||
buckets = get_tabs(piles->a, range);
|
||||
bucket_algo(piles, buckets, range);
|
||||
}
|
||||
}
|
||||
|
||||
void complex(t_stacks *piles)
|
||||
|
||||
Reference in new issue
Block a user