1个回答
展开全部
这是顺序:
VAR
i,n:longint;
a:array[1..100]of longint;
procedure make(le:longint);
begin
if le>n then exit;
write(a[le],' ');
make(le+1);
end;
BEGIN
readln(n);
for i:=1 to n do read(a[i]);
make(1);
END.
倒序:
var
i,n:longint;
a:array[1..100]of longint;
procedure make(le:longint);
begin
if le<n then make(le+1);
write(a[le],' ');
end;
BEGIN
readln(n);
for i:=1 to n do read(a[i]);
make(1);
END.
直接打上来的 有语法问题请见谅
VAR
i,n:longint;
a:array[1..100]of longint;
procedure make(le:longint);
begin
if le>n then exit;
write(a[le],' ');
make(le+1);
end;
BEGIN
readln(n);
for i:=1 to n do read(a[i]);
make(1);
END.
倒序:
var
i,n:longint;
a:array[1..100]of longint;
procedure make(le:longint);
begin
if le<n then make(le+1);
write(a[le],' ');
end;
BEGIN
readln(n);
for i:=1 to n do read(a[i]);
make(1);
END.
直接打上来的 有语法问题请见谅
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询