is_alpha Function

public elemental function is_alpha(c)

Checks whether c is an ASCII letter (A .. Z, a .. z).

Arguments

Type IntentOptional Attributes Name
character(len=1), intent(in) :: c

The character to test.

Return Value logical


Source Code

   elemental logical function is_alpha(c)
      character(len=1), intent(in) :: c
          !! The character to test.
      is_alpha = (c >= 'A' .and. c <= 'Z') .or. (c >= 'a' .and. c <= 'z')
   end function is_alpha