How to determines whether a character is a lowercase in C

1 Answer

0 votes
#include <stdio.h> 
#include <ctype.h> 

int main(void)
{   
	char ch = 'A';
	if (islower(ch))
		printf("yes\n");
	else
		printf("no\n");

	ch = 'a';
	if (islower(ch))
		printf("yes\n");
	else
		printf("no\n");

    return 0;
}

   
/*
run:

no
yes

*/

 



answered Dec 6, 2016 by avibootz

Related questions

1 answer 160 views
1 answer 170 views
1 answer 191 views
1 answer 161 views
1 answer 146 views
1 answer 188 views
...