为什么网上找的C语言贪吃蛇程序都只能通过编译而不能运行

来源:百度知道 编辑:UC知道 时间:2024/05/19 03:40:36
还是不行
很多东西没无法找到~

你要看看有没有字符错误,有可能传到网上会出现全角这种错误!
我这里有个程序,供你参考,测试过了可运行
#include "graphics.h"
#include "stdio.h"

#define MAX 200
#define MAXX 30
#define MAXY 30

#define UP 18432
#define DOWN 20480
#define LEFT 19200
#define RIGHT 19712
#define ESC 283
#define ENTER 7181
#define PAGEUP 18688
#define PAGEDOWN 20736
#define KEY_U 5749
#define KEY_K 9579
#define CTRL_P 6512
#define TRUE 1
#define FALSE 0
#define GAMEINIT 1
#define GAMESTART 2
#define GAMEHAPPY 3
#define GAMEOVER 4

struct SPlace
{
int x;
int y;
int st;
} place[MAX];
int speed;
int count;
int score;
int control;
int head;
int tear;
int x,y;
int babyx,babyy;
int class;
int eat;
int game;
int gamedelay[]={5000,4000,3000,2000,1000,500,250,100};
int gamedelay2[]={1000,1};
stati