-
Notifications
You must be signed in to change notification settings - Fork 0
/
ra.c
29 lines (26 loc) · 1.1 KB
/
ra.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
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ra.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: zessadqu <[email protected]> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2022/05/19 11:36:40 by zessadqu #+# #+# */
/* Updated: 2022/06/04 11:32:46 by zessadqu ### ########.fr */
/* */
/* ************************************************************************** */
#include "check_header.h"
void rotate_a(t_nums **a)
{
t_nums *tmp;
tmp = *a;
if (!(*a))
return ;
while ((*a)->next)
*a = (*a)->next;
(*a)->next = tmp;
tmp = tmp->next;
(*a) = (*a)->next;
(*a)->next = NULL;
(*a) = tmp;
}