Exemplo n.º 1
0
static void		glob_recursion_boucle(char ***res, char ***files, char *temp[3])
{
	while (res[0][0] != NULL)
	{
		*files = add_double_char(*res, *files);
		temp[1] = ft_strjoin(temp[0], "/");
		free(temp[0]);
		temp[0] = ft_insert(temp[1]);
		free(temp[1]);
		*res = launch(temp[0]);
	}
	free_double_char(*res);
	free(temp[0]);
}
Exemplo n.º 2
0
t_l			*ft_deal(t_l *lst)
{
	t_l		*lst2;
	int		nb;

	nb = ft_count(lst);
	if (nb <= 20)
	{
		lst2 = ft_lstcpy(lst);
		lst2 = ft_insert(lst, lst2);
	}
	else
	{
		lst2 = ft_lstncpy(lst, nb);
		lst2 = ft_trif(lst2, nb);
	}
	return (lst2->first);
}
Exemplo n.º 3
0
void ft_btoa(t_swap *swap)
{
	swap->a = ft_insert(swap->b[array_size(swap->b) - 1], swap->a, 1);
	swap->b = ft_delete(swap->b, 1);
}
Exemplo n.º 4
0
void ft_atob(t_swap *swap)
{
swap->b = ft_insert(swap->a[array_size(swap->a) - 1], swap->b, 1);
swap->a = ft_delete(swap->a, 1);
}