I\'ve been working on the readability problem in CS50. The first step is to create a way to count only the alphabetical characters. It suggests to use the isalpha f
isalpha
#include <stdio.h> #include <stdlib.h> #include <string.h> #include <ctype.h> int main(void) { const char* s = get_string ("Text: \n"); int count = 0; while(*s) count += !!isalpha(*s++); printf ("%d\n", count ); return 0; }