C Program to Check For Pangram String
This tutorial explains c program to check for pangram string with C source code, sample output, and step-by-step execution flow.
#include <stdio.h>
#include <ctype.h>
int main() {
char str[] = "The quick brown fox jumps over the lazy dog";
int seen[26] = {0}, i, count = 0;
for (i = 0; str[i]; i++) if (isalpha(str[i])) seen[tolower(str[i]) - 'a'] = 1;
for (i = 0; i < 26; i++) count += seen[i];
if (count == 26) printf("Pangram string
");
else printf("Not a pangram string
");
return 0;
}
Pangram string
In this program, the input is read first when required, the core logic is applied step by step, and the final result is displayed using printf(). Follow the execution flow beside the code to understand how each statement contributes to the output.
