Development C

#include
#define MAXARR 26
int main(int argc, char *argv[]) {
float freq[MAXARR] = {0};
int nc[MAXARR] = {0};
int c = 0, i = 0;
int count = 0;
while((c = getchar()) != EOF) {
if(c >= 'A' && c <= 'Z')
nc[c - 'A']++;
else if(c >= 'a' && c <= 'z')
nc[c - 'a']++;
count++;
}
for(i = 0; i < MAXARR; i++)
freq[i] = (float)nc[i] / (float)count;
for(i = 0; i < MAXARR; i++)
printf("%c %f\n", 'A' + i, freq[i]);
return 0;
}