expected but "ELSE" found
来源:学生作业帮 编辑:作业帮 分类:综合作业 时间:2024/08/29 02:37:18
expected but "ELSE" found
program ex111;
var
a:array[1..100] of integer;
n,i,ans,len,tmp,beg:integer;
begin
read(n);
for i:=1 to n do
read(a[i]);
tmp:=0;
ans:=0;
len:=0;
beg:=0;
for i:=1 to n do
begin
if tmp+a[i]>ans then
begin
ans:=tmp+a[i];
len:=i-beg;
end;
else if (tmp+a[i]=ans) and (i-beg>len) then
len:=i-beg
if tmp+a[i]
program ex111;
var
a:array[1..100] of integer;
n,i,ans,len,tmp,beg:integer;
begin
read(n);
for i:=1 to n do
read(a[i]);
tmp:=0;
ans:=0;
len:=0;
beg:=0;
for i:=1 to n do
begin
if tmp+a[i]>ans then
begin
ans:=tmp+a[i];
len:=i-beg;
end;
else if (tmp+a[i]=ans) and (i-beg>len) then
len:=i-beg
if tmp+a[i]
主要是else前面的end后面应该没有;号.
program ex111;
var
a:array[1..100] of integer;
n,i,ans,len,tmp,beg:integer;
begin
read(n);
for i:=1 to n do
read(a[i]);
tmp:=0;
ans:=0;
len:=0;
beg:=0;
for i:=1 to n do
begin
if tmp+a[i]>ans then
begin
ans:=tmp+a[i];
len:=i-beg;
end
else if (tmp+a[i]=ans) and (i-beg>len) then
len:=i-beg;
if tmp+a[i]
program ex111;
var
a:array[1..100] of integer;
n,i,ans,len,tmp,beg:integer;
begin
read(n);
for i:=1 to n do
read(a[i]);
tmp:=0;
ans:=0;
len:=0;
beg:=0;
for i:=1 to n do
begin
if tmp+a[i]>ans then
begin
ans:=tmp+a[i];
len:=i-beg;
end
else if (tmp+a[i]=ans) and (i-beg>len) then
len:=i-beg;
if tmp+a[i]
Nothing else but love
英语翻译As might have been expected,the research found littlein
______to this problem is expected to be found before long .
but,I miss someone else.Bless you
英语翻译She answers nearly everything else,however.She has found
What we have lost somewhere must be found somewhere else.
英语翻译He had expected gratitude for his disclosure,but instead
Twenty people were expected,but only ten ___.
The book you lent me is not what I expected. I found什么 mysel
单选题:A ___ to this problem is expected to be found before lon
He never expected the bicycle to be found.其中的bo be thanks.
显示说 the expected version of the product was not found on you