digito [0-9] letra [a-zA-Z] alfanumerico [a-zA-Z0-9] puntuacion [\.,:;-_\[\]\{\}Ώ?‘!()""''] id letra|letra[alfanumerico|_]* operador [“or” | “and” | “not” | “<” | “<=” | “>” | “>=” | “==” | “!=” | “+” | “*” | “/” | “-“] %% {id} { printf ("T_ID:%s ", yytext); } "\""[{alfanumerico}|{puntuacion}]*"\"" {printf("T_LITCADENA:%s ", yytext);} "\'"[{alfanumerico}|{puntuacion}]"\'" {printf("T_LITCARACTER:%s ", yytext);} [0|[1-9]{digito}]* {printf("T_LITENTERO:%s ", yytext);} [Tt][Rr][Uu][Ee] | [Ff][Aa][Ll][Ss][Ee] {printf("T_LITBOOLEANO:%s ", yytext);} "--"[{letra} | {digito} | {puntuacion}]*\n {printf("T_COMENTARIO:%s ", yytext);} char {printf("T_TIPOCHAR ");} int {printf("T_TIPOENTERO ");} bool {printf("T_TIPOBOOLEANO ");} void {printf("T_TIPOVOID ");} "=" {printf("T_OPERIGUAL ");} "!=" {printf("T_OPERDISTINTO ");} ">=" {printf("T_OPERMAYORIGUAL ");} "<=" {printf("T_OPERMENORIGUAL ");} and {printf("T_OPERAND ");} or {printf("T_OPEROR ");} not {printf("T_OPERNOT ");} put {printf("T_FUNESCRIBIR ");} read {printf("T_FUNLEER ");} if {printf("T_IF ");} then {printf("T_THEN ");} else {printf("T_ELSE ");} while {printf("T_WHILE ");} return {printf("T_RETURN ");} %%