%{ // Afficher les sous-titres d'un fichier ".sub" aux temps indiqu�s. int t1=0; int t2=0; %} %% ^\{[0-9]+/\} { usleep((t2-t1)*1000000/24); t1=atoi(yytext+1); system("clear"); usleep((t1-t2)*1000000/24); printf("t1:%d ; ", t1); } \{[0-9]+/\} { t2=atoi(yytext+1); printf("t2:%d ; ", t2); } [^}{|\n][^|\n]+ { printf("%s\n", yytext);//line 1 } \|[^|\n]+ { printf("%s\n", yytext+1);//line 2 } . {} %%