这个程序为什么不能运行???哪个高手知道!!!
#include<iostream.h>#include<fstream.h>
#include<iomanip.h>
class Euler
{
public:
Euler(int m,n,u,v);
private:
double m,n,u,v;
};
int main()
{
int m,n,u,v;
ifstream in("input.txt");
in>>n>>" ">>m>>"\n";
in>>u>>" ">>v>>"\n";
ofstream out("output.txt");
out<<c1.sround1()<<" "<<c1.circle1()<<endl;
const n;//顶点数//
type shuzu=array[n][n]
const a:shuzu //图的描述与定义 1:连通;0:不通//
var
bianshu:array[1..max]of 0..max; //与每一条边相连的边数//
path:array[0..1000]of integer; //记录画法,只记录顶点//
zongbianshu,uu,first,u,total:integer;
procedure output(dep:integer); //输出各个顶点的画法顺序//
var sum,u,v:integer;
begin
inc(total);
writeln('total:',total);
for u:=0 to dep do write(Path);writeln;
end;
function ok(now,u:integer;var next:integer):boolean;//判断第I条连接边是否已行过//
var v,vv:integer;
begin
v:=0; vv:=0;
while vv<>u do begin inc(v);if a[now,u]<>0 then inc(vv);end;
next:=v;//判断当前顶点的第I条连接边的另一端是哪个顶点,找出后赋给NEXT传回//
ok:=true;
if (a[now,j]<>1) then ok:=false; {A[u,v]=0:原本不通}
end; { =2:曾走过}
procedure init;// {初始化}
var u,v :integer;
begin
total:=0; //{方案总数}
zongbianshu:=0; //{总边数}
for u:=1 to n do
for v:=1 to n do
if a[u,v]<>0 then begin inc(bianshu);inc(zongbianshu);end;//求与每一边连接的边数bianshu//
zongbianshu:=zongbianshu div 2; //图中的总边数//
end;
procedure find(dep,nowpoint:integer); //dep:画第几条边;nowpoint:现在所处的顶点//
var u,next,v:integer;
begin
for u:=1 to bianshu[nowpoint] do //与当前顶点有多少条相接,则有多少种走法//
if ok(nowpoint,i,next) then begin //与当前顶点相接的第I条边可行吗?//
//如果可行,其求出另一端点是NEXT//
a[nowpoint,next]:=2; a[next,nowpoint]:=2; //置成已走过标志//
path[dep]:=next; //记录顶点,方便输出//
if dep < zongbianshu then find(dep+1,next) //未搜索完每一条边//
else output(dep)
path[dep]:=0; //回溯//
a[nowpoint,next]:=1; a[next,nowpoint]:=1;
end;
begin
init; //初始化,求边数等//
for first:=1 to n do //分别从各个顶点出发,尝试一笔画//
fillchar(path,sizeof(path),0);
path[0]:=first; //记录其起始的顶点//
writeln('from point ',first,':');readln;
find(1,first); //从起始点first,一条边一条边地画下去//
end.