主题:rrrr
016565
[专家分:0] 发布于 2009-07-26 13:25:00
打印如下图形
1 50(分(第一个做对) 1 0 0 0 0
2 1 0 0 0
2 2 1 0 0
2 2 2 1 0
2 2 2 2 1
2 30(分) 1
3 3 3
1 1 1 1 1
3 3 3 3 3
1 1 1
3
回复列表 (共2个回复)
沙发
FFKK [专家分:1610] 发布于 2009-07-26 13:31:00
1
cls
for i=1 to 5
for j=1 to 5
if i>j then
a(i,j)=2
else
if i<j then a(i,j)=0 else a(i,j)=1
end if
next j
next i
for i=1 to 5
for j=1 to 5
? a(i,j);
next j
?
next i
end
板凳
FFKK [专家分:1610] 发布于 2009-07-26 13:36:00
2
for i=1 to 3
for j=1 to 5 step 2
if 3 mod i =0 then
? "1";
else
? "3";
end if
next j
?
next i
for k=3 to 1 step -1
for l=5 to 1 step -2
if 3 mod i=0 then
? "3";
else
? "1";
end if
next j
?
next i
end
我来回复