求教用VB 写程序.求两自然数m,n的最小公倍数.这样写对吗?
求教用VB 写程序.求两自然数m,n的最小公倍数.这样写对吗?
Dim a%,b%,t%,i%
a=inputbox(“第1个数”):b=inputbox(“第2个数”)
If a
Dim a%,b%,t%,i%
a=inputbox(“第1个数”):b=inputbox(“第2个数”)
If a
数学人气:971 ℃时间:2020-03-27 20:50:32
优质解答
给你另外一种求法Dim a As LongDim b As LongDim t As Longa = 42b = 30t = aDim result As Longresult = 1For i = 1 To tIf (a Mod i) = 0 And (b Mod i) = 0 Thena = a / ib = b / ir...
我来回答
类似推荐