求解一道QB的题,quickbasic语句.(1+1/3+1/5+1/7+1/9)-(1/2+1/4+1/6+1/8+1/10)

来源:学生作业帮助网 编辑:六六作业网 时间:2024/11/16 12:04:48
求解一道QB的题,quickbasic语句.(1+1/3+1/5+1/7+1/9)-(1/2+1/4+1/6+1/8+1/10)求解一道QB的题,quickbasic语句.(1+1/3+1/5+1/7

求解一道QB的题,quickbasic语句.(1+1/3+1/5+1/7+1/9)-(1/2+1/4+1/6+1/8+1/10)
求解一道QB的题,quickbasic语句.(1+1/3+1/5+1/7+1/9)-(1/2+1/4+1/6+1/8+1/10)

求解一道QB的题,quickbasic语句.(1+1/3+1/5+1/7+1/9)-(1/2+1/4+1/6+1/8+1/10)
Basic好久不用了,不知道有没有语法错误
DIM S#, K#
S=0: K=1
For i = 1 To 10
S = S + 1.0 / i
K = -K
Next i
Print S