Saturday, 8 September 2018

Write a LEX program to check whether inputted character is vowel or not.


%{
%}
%%
[aeiouAEIOU]              {printf("Input is a vowel");}
[A-Za-z(^aeiouAEIOU)]     {printf("Input is not a vowel");}
%%
main()
{
     yylex();
}
int yywrap()
{
     return 1;
}

No comments:

Post a Comment

It's time To increase blogging capability. To have a chance to contribute in digital world. Any Interested People who want to make t...