-
Notifications
You must be signed in to change notification settings - Fork 0
/
push_swap.h
47 lines (42 loc) · 1.71 KB
/
push_swap.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* push_swap.h :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: bsyvasal <[email protected]> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2023/12/14 13:55:39 by bsyvasal #+# #+# */
/* Updated: 2024/01/09 09:43:36 by bsyvasal ### ########.fr */
/* */
/* ************************************************************************** */
#ifndef PUSH_SWAP_H
# define PUSH_SWAP_H
# include <stdio.h>
# include "libft/libft.h"
typedef struct s_stacks
{
int *a;
int *b;
int asize;
int bsize;
} t_stacks;
int turk_sort(t_stacks *st, int print);
int simple_sort(t_stacks *st, int print);
int validate_and_count(char **list);
int calc_count(int acount, int bcount);
int is_ordered(int arr[], int size);
int sa(t_stacks *st, int print);
int sb(t_stacks *st, int print);
int ss(t_stacks *st, int print);
int pa(t_stacks *st, int print);
int pb(t_stacks *st, int print);
int ra(t_stacks *st, int print);
int rb(t_stacks *st, int print);
int rr(t_stacks *st, int print);
int rra(t_stacks *st, int print);
int rrb(t_stacks *st, int print);
int rrr(t_stacks *st, int print);
void revrot(int *a, int size);
void rotate(int *a, int size);
void free_stringarray(char **list);
#endif