input.txt

来自「一个词法分析程序。是编译原理完成的一个作业」· 文本 代码 · 共 46 行

TXT
46
字号
asdfsdf7  , -8 asdf242314jgkasf   adfsdf& =  == === {"if",IF},{"else",ELSE},
/* Copyright (c) 1987,88 by Borland International, Inc.

   This module demonstrates how to write Turbo C routines that
 */

typedef unsigned int word;
typedef unsigned char byte;
typedef unsigned long longword;

extern void setcolor(byte newcolor);  /* procedure defined in
                                         Turbo Pascal program */

word sqr(int i)
{
  setcolor(1);
  return(i * i);
} /* sqr */


byte upr(byte c)
{
  setcolor(4);
  return((c >= 'a') && (c <= 'z') ? c - 32 : c);
} /* upr */

char prd(char s)
{
  setcolor(5);
  return(--s);
} /* prd */

long lobits(long l)
{
  setcolor(6);
  return((longword)l & 65535L);
} /* lobits */

void strupr(char *s)
{
  int counter;

  for (counter = 1; counter <= s[0]; counter++)  /* Note that the routine */
    s[counter] = upr(s[counter]);                /* skips Turbo Pascal's  */
  setcolor(7);                                   /* length byte           */
} /* strupr

⌨️ 快捷键说明

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