1樓:匿名使用者
①min=0
②x>=max
③x<=min
④題上無空
⑤s=s-max-min
用vb做一個評分程式
2樓:匿名使用者
iftext1.text="123"thentext2.text="159"elseiftext1.
text="5"thentext2.text="6"elsetext2.text="不存在"endif放在按鈕單擊事件中
用vb編寫自動評分程式
vb編寫一計算機自動出題並判斷對錯的程式
3樓:巨星李小龍
程式在附件中,望採納!
4樓:數字化技能分享家
150155942qq把全部程式發過來看看吧。
用vb設計一個1~10數的四則運算的算術題自動評分程式
5樓:匿名使用者
dim a, b, i, j, h as integer, c(1 to 4), d as string
private sub command1_click()
a = int(rnd * 11)
b = int((rnd * 10) + 1)
c(1) = "+": c(2) = "-": c(3) = "*": c(4) = "/"
j = int((rnd * 4) + 1)
d = c(j)
label1.caption = a & d & b & "=" & "?"
label1.refresh
command1.enabled = false
end sub
private sub command2_click()
i = i + 1
if d = c(1) then
if text1.text = a + b then
msgbox "恭喜你,計算正確"
h = h + 1
text1.text = ""
command1.enabled = true
label2.caption = "共" & i & "道題," & "答對" & h & "道題。"
label2.refresh
else
msgbox "真遺憾,計算錯誤"
text1.text = ""
command1.enabled = true
label2.caption = "共" & i & "道題," & "答對" & h & "道題。"
label2.refresh
end if
elseif d = c(2) then
if text1.text = a - b then
msgbox "恭喜你,計算正確"
h = h + 1
text1.text = ""
command1.enabled = true
label2.caption = "共" & i & "道題," & "答對" & h & "道題。"
label2.refresh
else
msgbox "真遺憾,計算錯誤"
text1.text = ""
command1.enabled = true
label2.caption = "共" & i & "道題," & "答對" & h & "道題。"
label2.refresh
end if
elseif d = c(3) then
if text1.text = a * b then
msgbox "恭喜你,計算正確"
h = h + 1
text1.text = ""
command1.enabled = true
label2.caption = "共" & i & "道題," & "答對" & h & "道題。"
label2.refresh
else
msgbox "真遺憾,計算錯誤"
text1.text = ""
command1.enabled = true
label2.caption = "共" & i & "道題," & "答對" & h & "道題。"
label2.refresh
end if
elseif d = c(4) then
if cdbl(text1.text) = a / b then
msgbox "恭喜你,計算正確"
h = h + 1
text1.text = ""
command1.enabled = true
label2.caption = "共" & i & "道題," & "答對" & h & "道題。"
label2.refresh
else
msgbox "真遺憾,計算錯誤"
text1.text = ""
command1.enabled = true
label2.caption = "共" & i & "道題," & "答對" & h & "道題。"
label2.refresh
end if
end if
end sub
6樓:匿名使用者
樓上的程式要再做修改一下。小學四則運算中的除法好像還不能出現除不盡的情況吧。9÷3=3可以。9÷4=2.25好像不行吧。。。
計算機的VB程式是什麼啊
vb visual basic是在來 windows下進行應用程式設計的編自程工具,現在一般bai的計算機用du zhi戶幾乎都不再使用dos了,因此我們通常會選擇daovisual basic作為初學者的程式設計工具。visual basic是windows應用程式設計中最容易上手的程式設計工具,...
用VB編寫程式,用VB編寫一個程式
樓上的,不許要引用吧 option explicit private declare function getdrivetype lib kernel32 alias getdrivetypea byval ndrive as string as long private declare funct...
計算機VB程式設計試題
不難的sub shuzu dim a 3,4 as integerdim i,j,k as integerfor i 0 to 3 for j 0 to 4 a i,j int rnd 151 50 k k 1 print format str a i,j 000 為了對齊 if k mod 5 0...