附我写的程序:
*背单词2,取随机数出题,抽查全部的学习内容
set exac on
modi window screen font "宋体" ,16
clea
a=time()
use 学英语
al=recc()
repl all 备注 with ''
go 1
j=1
do while .not.eof()
do while .t.
i=int(rand(-1)*al)
i=i+1
go i
if 备注=' '
exit
else
count for 备注='已测试' to m
if m=al
?'已完毕'
b=time()
c=val(substr(b,1,2))*60*60+val(substr(b,4,2))*60+val(substr(b,7,2))-(val(substr(a,1,2))*60*60+val(substr(a,4,2))*60+val(substr(a,7,2)))
d="用时:"-str(int(c/60))-":"-ltrim(str(mod(c,60)))
?d
return
endif
endif
enddo
do while .t.
@18,20 say j
@20,2 say 词性+词义
accept '英语拼写:' to m
if m=trim(dc)
repl 备注 with '已测试'
j=j+1 &&计数器
exit &&正确了才跳出来,否则持续回答
endif
@21,0 say space(100)
enddo
@21,0 say space(100)
enddo