cal.l

来自「lex files for given decription used as 」· L 代码 · 共 64 行

L
64
字号
%{#include <stdio.h>#include <unistd.h>#include <stdlib.h>#include <math.h>#define YYSTYPE double#include "y.tab.h"extern YYSTYPE yylval;%}digit [0-9]space [ \t]%%{space}         { ; }    /* spaces are ignored */{digit}+\.?|{digit}*\.{digit}+ {                    yylval = strtod(yytext,0);                    return NUMBER; }\*\*            { return '^';  }cos             { return COS;  }exp             { return EXP;  }sin             { return SIN;  }sqrt            { return SQRT; }tan             { return TAN;  }\n              { return '\n'; }.               { return yytext[0]; }%%

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?