%{ int v=0,c=0; %} %% [aeiouAEIOU] v++; [a-zA-z] c++; %% main() { printf("enter input:\n"); yylex(); printf("vowels=%d\n consonants=%d\n",v,c); } int yywrap() { return l; }
Standard input is empty
Standard output is empty
ERROR: /home/XYX74Y/prog:17:1: Syntax error: Unexpected end of file ERROR: '$runtoplevel'/0: Undefined procedure: program/0 Exception: (3) program ? EOF: exit