%{
#include<stdio.h>
int flag=0;
%}
%%
and |
or |
but |
because |
if |
then |
nevertheless { flag=1; }
. ;
\n { return 0; }
%%
int main()
{
printf("Enter the sentence:\n");
yylex();
if(flag==0)
printf("Simple sentence\n");
else
}
int yywrap( )
{
return 1;
}
JXsKCSNpbmNsdWRlPHN0ZGlvLmg+CglpbnQgZmxhZz0wOwolfQoKJSUKYW5kIHwKb3IgfApidXQgfApiZWNhdXNlIHwKaWYgfAp0aGVuIHwKbmV2ZXJ0aGVsZXNzICB7IGZsYWc9MTsgfQouICA7ClxuICB7IHJldHVybiAwOyB9CiUlCgppbnQgbWFpbigpCnsKCXByaW50ZigiRW50ZXIgdGhlIHNlbnRlbmNlOlxuIik7Cgl5eWxleCgpOwoJaWYoZmxhZz09MCkKCQlwcmludGYoIlNpbXBsZSBzZW50ZW5jZVxuIik7CgllbHNlCgkJcHJpbnRmKCJjb21wb3VuZCBzZW50ZW5jZVxuIik7Cn0KCmludCB5eXdyYXAoICkKewoJcmV0dXJuIDE7Cn0=