fork download
  1. :- set_prolog_flag(verbose,silent).
  2. :- prompt(_, '').
  3. :- use_module(library(readutil)).
  4.  
  5. main:-
  6. process,
  7.  
  8. process:-
  9. /* your code goes here */
  10.  
  11. :- main.
  12. %{
  13. #include <stdio.h>
  14. #include <ctype.h>
  15. %}
  16.  
  17. %%
  18. [a-z]+ {
  19. int i;
  20. for (i = 0; yytext[i] != '\0'; i++)
  21. putchar(toupper(yytext[i]));
  22. }
  23.  
  24. .|\n { putchar(yytext[0]); }
  25. %%
  26.  
  27. int main()
  28. {
  29. yylex();
  30. return 0;
  31. }
  32.  
Success #stdin #stdout 0.03s 6304KB
stdin
Standard input is empty
stdout
Standard output is empty