主题:分解某个数的所有因子
input "x=";x
if x=0 then
print "无因子"
End
Else
print SGN(x)
end if
call ((x))
print "=";x
end
sub s(x as integer)
x=ABS(x)
for i=2 to x/2
while x mod i=0
print "*";i
k=k\i
WEND
if x<>1 then print "x";
next i
END SUB
发现好多编程真的是很麻烦啊!有时侯很好理解的数学题,就好多种复杂的编程.
大家讨论一下更简单的方法啊!!对待编程是不是要有很好的头脑啊!数学还是关键啊!
我的变成一直就是弱相啊!!想要学好编程,请多给点意见啊!!!!
怎么学好编程啊!!一直是我的头痛啊!!
if x=0 then
print "无因子"
End
Else
print SGN(x)
end if
call ((x))
print "=";x
end
sub s(x as integer)
x=ABS(x)
for i=2 to x/2
while x mod i=0
print "*";i
k=k\i
WEND
if x<>1 then print "x";
next i
END SUB
发现好多编程真的是很麻烦啊!有时侯很好理解的数学题,就好多种复杂的编程.
大家讨论一下更简单的方法啊!!对待编程是不是要有很好的头脑啊!数学还是关键啊!
我的变成一直就是弱相啊!!想要学好编程,请多给点意见啊!!!!
怎么学好编程啊!!一直是我的头痛啊!!