/* ************************************************************************** */
/*                                                                            */
/*                                                        :::      ::::::::   */
/*   ft_sorting.h                                       :+:      :+:    :+:   */
/*                                                    +:+ +:+         +:+     */
/*   By: alier <alier@student.42mulhouse.fr>        +#+  +:+       +#+        */
/*                                                +#+#+#+#+#+   +#+           */
/*   Created: 2024/11/04 16:45:04 by alier             #+#    #+#             */
/*   Updated: 2025/01/17 11:07:18 by alier            ###   ########.fr       */
/*                                                                            */
/* ************************************************************************** */

#ifndef FT_SORTING_H
# define FT_SORTING_H
# include <stddef.h>
# include "../libft.h"

struct s_countsort
{
	size_t			size;
	unsigned int	*a;
	unsigned int	exp;
	unsigned int	*tmp;
	unsigned int	*count;
};

typedef int	(*t_compar)(const void *, const void *);

int		compare_strs_ptrs_asc(const void *a, const void *b);
void	ft_naive_radixsort(size_t size, unsigned int a[size]);
void	ft_naive_bubblesort_int_asc(int *base, size_t size);
void	ft_naive_bubblesort(void *base, size_t nmemb, size_t size,
			t_compar compar);

#endif