#include <stdio.h>

int	ft_isalnum(int c)
{
	if ((c >= 'A' && c <= 'Z') || (c >= 'a' && c <= 'z')
		|| (c >= '0' && c <= '9'))
	{
		return (1);
	}
	else
	{
		return (0);
	}
}

int	main(void)
{
	char	c;

	c = '-';
	if (ft_isalnum(c))
	{
		printf("Le caractere (%c) est bien un caractere alphanumerique", c);
	}
	else
	{
		printf("Le caractere (%c) n'est pas un caractere alphanumerique", c);
	}
	printf("\n");
	return (0);
}

Embed on website

To embed this project on your website, copy the following code and paste it into your website's HTML: