#include <stdio.h>
#include<string.h>
int main()
{
char str[100] ;
int i, j;
printf("Enter your String:\n\n");
scanf("%[^\n]",str);
for(i = 0; str[i] != '\0'; ++i)
{
while (((str[i] >= 'a' && str[i] <= 'z') || (str[i] >= 'A' && str[i] <= 'Z') || str[i] == '\0') )
{
for(j = i; str[j] != '\0'; ++j)
{
str[j] = str[j+1];
}
str[j] = '\0';
}
}
printf(" After removing alphabetical characters the string is :");
puts(str);
return 0;
}
To embed this project on your website, copy the following code and paste it into your website's HTML: