Panagram in c

#include<stdio.h>
#include<conio.h>
#include<string.h>

int main()
{
int x[26]={0},i,n;
char c[100];
clrscr();
gets(c);
n=strlen(c);
for(i=0;i<n;i++)
{
if(c[i]>=65&&c[i]<=90)
x[c[i]-26]++;
else if(c[i]>=97&&c[i]<=122)
x[c[i]-97]++;
}
for(i=0;i<26;i++)
{
if(x[i]==0)
{
break;
}
}
if(i==26)
{
printf(“panagram”);
}
else
{
printf(“not panagram”);
}
return 0;
}

Leave a Reply

Your email address will not be published. Required fields are marked *