ft_isascii

nawkim·2021년 5월 26일
0

libft

목록 보기
4/44

1. 프로토타입

int	ft_isascii(int c)
  • 헤더
#include <ctype.h>
  • 형태
int	isascii(int c)

2. 용도

아스키코드에 해당하는지 아닌지 확인.

3. 리턴값

아스키코드(0 ~ 127)에 해당한다면 1, 아니면 0을 반환.

4. 코드 구현

int	ft_isascii(int c)
{
	if (c >= 0 && c <= 127)
		return (1);
	return (0);
}
profile
공부 기록.

0개의 댓글