-
Notifications
You must be signed in to change notification settings - Fork 0
/
costs3.c
63 lines (58 loc) · 1.89 KB
/
costs3.c
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
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* costs3.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: imontero <imontero@student.42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2023/09/01 08:34:10 by imontero #+# #+# */
/* Updated: 2023/09/01 10:06:31 by imontero ### ########.fr */
/* */
/* ************************************************************************** */
#include "push_swap.h"
void costs_final_balance_aux_r(t_ps *ps, int i)
{
ps->costs[i][0] = ps->r_balan;
ps->costs[i][4] = 0;
ps->costs[i][5] = 0;
ps->costs[i][6] = 0;
ps->costs[i][7] = 0;
ps->costs[i][8] = 0;
ps->costs[i][9] = 0;
ps->costs[i][10] = 0;
}
void costs_final_balance_aux_rr(t_ps *ps, int i)
{
ps->costs[i][0] = ps->rr_balan;
ps->costs[i][1] = 0;
ps->costs[i][2] = 0;
ps->costs[i][3] = 0;
ps->costs[i][7] = 0;
ps->costs[i][8] = 0;
ps->costs[i][9] = 0;
ps->costs[i][10] = 0;
}
void costs_final_balance_aux_r_rr(t_ps *ps, int i)
{
ps->costs[i][0] = ps->r_rr_balan;
ps->costs[i][1] = 0;
ps->costs[i][2] = 0;
ps->costs[i][3] = 0;
ps->costs[i][4] = 0;
ps->costs[i][5] = 0;
ps->costs[i][6] = 0;
ps->costs[i][9] = 0;
ps->costs[i][10] = 0;
}
void costs_final_balance_aux_rr_r(t_ps *ps, int i)
{
ps->costs[i][0] = ps->rr_r_balan;
ps->costs[i][1] = 0;
ps->costs[i][2] = 0;
ps->costs[i][3] = 0;
ps->costs[i][4] = 0;
ps->costs[i][5] = 0;
ps->costs[i][6] = 0;
ps->costs[i][7] = 0;
ps->costs[i][8] = 0;
}