|
发表于 2012-5-15 09:54:50
|
显示全部楼层
本帖最后由 netegg 于 2012-5-15 18:24 编辑
[au3]#include <Math.au3>
#include <array.au3>
Dim $s[4]
$s[0] = 3
main()
Func main()
Local $input, $ret = '', $i = 1
MsgBox(0,0,'请记住一个数' & @CRLF & '10,11,12,13,14,15,16' & @CRLF & '17,18,19,20,21,22,23'& @CRLF & '24,25,26,27,28,29,30')
Do
$aA1 = _RandomUnique(21, 10, 30, 1)
$s[1] = _ArrayToString($aA1, ',', 1, 7)
$s[2] = _ArrayToString($aA1, ',', 8, 14)
$s[3] = _ArrayToString($aA1, ',', 15, 21)
$input = InputBox('输入选定数所在行', $s[1] & @CRLF & $s[2] & @CRLF & $s[3], '')
If @error Then Exit
$ret &= $s[$input] & ','
$i += 1
Until $i = 4
$aRet = StringSplit($ret, ',', 2)
For $i In $aRet
If UBound(_ArrayFindAll($aRet, $i)) = 3 Then
$msg = MsgBox(4, 0, $i & @CRLF & 'exit?')
If $msg = 6 Then Exit
$s[0] = 0
$s[0] = 3
main()
EndIf
Next
EndFunc ;==>main
[/au3] |
|