2个回答
展开全部
Dim A(3)
While A(0) = A(1) Or A(0) = A(2) Or A(0) = A(3) Or A(1) = A(2) Or A(1) = A(3) Or A(2) = A(3)
Randomize
A(0) = Int(4 * Rnd())
A(1) = Int(4 * Rnd())
A(2) = Int(4 * Rnd())
A(3) = Int(4 * Rnd())
Wend
Option1.Caption = Chr(65 + A(0))
Option2.Caption = Chr(65 + A(1))
Option3.Caption = Chr(65 + A(2))
Option4.Caption = Chr(65 + A(3))
While A(0) = A(1) Or A(0) = A(2) Or A(0) = A(3) Or A(1) = A(2) Or A(1) = A(3) Or A(2) = A(3)
Randomize
A(0) = Int(4 * Rnd())
A(1) = Int(4 * Rnd())
A(2) = Int(4 * Rnd())
A(3) = Int(4 * Rnd())
Wend
Option1.Caption = Chr(65 + A(0))
Option2.Caption = Chr(65 + A(1))
Option3.Caption = Chr(65 + A(2))
Option4.Caption = Chr(65 + A(3))
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询