zfc1987 发表于 2007-12-19 13:00

VF (程序设计)

编辑把一个字符串首尾颠倒排序

zfc1987 发表于 2007-12-19 13:08

clear
x=""

@1,2 say"请输入字符:" get s default space(20)
read

for i=1 to len(s)
x=substr(s,i,1)+x
endf
?x

zfc1987 发表于 2007-12-19 13:08

clear
x=""

@1,2 say"请输入字符:" get s default space(20)
read

for i=1 to len(s)
x=substr(s,i,1)+x
endf
?x

zfc1987 发表于 2007-12-19 13:09

clear
x=""

@1,2 say"请输入字符:" get s default space(20)
read

for i=1 to len(s)
x=substr(s,i,1)+x
endf
?x

zfc1987 发表于 2007-12-19 13:12

clear
accept "请输入一个字符串: " to a default space(20)
for b=len(a) to 1 step -1
??space(20)+substr(a,b,1)
endfor

页: [1]

编程论坛