by ShadyMan (1 Submission)
Category: Games
Compatability: VB 6.0
Difficulty: Unknown Difficulty
Originally Published: Tue 27th March 2001
Date Added: Mon 8th February 2021
Rating: (1 Votes)
The Punch Board game from "The Price is Right"
API Declarations
dim con as integer
count1= 0
Do
num2= val(inputbox("Enter in a number between 1 and 60","Enter Number"))
amount= num(num2)
picoutput.print "The amount in that box is "; FormatCurrency(amount);"."
con= MsgBox("Do you want to continue?", vbQuestion + vbYesNo,"Continue")
If con= vbNo then
count1= 5
Elseif con= vbYes then
count1= count1 +1
End If
Loop Until count1=5
End Sub
Private Sub Form_Load()
Randomize
count1= 0
Do
num1= int(60 *Rnd)+1
If num(num1) = 0 then
count1= count1 +1
num(num1)= 100
End if
Loop Until count1= 20
count1= 0
Do
num1= int(60*Rnd)+1
If num(num1)= 0 then
count1= count1 +1
num(num1)= 250
End If
Loop Until count1= 16
count1= 0
Do
num1= int(60*Rnd)+1
If num(num1)= 0 then
count1= count1 +1
num(num1)= 500
End If
Loop Until count1= 12
count1= 0
Do
num1= int(60*Rnd)+1
If num(num1)= 0 then
count1= count1 +1
num(num1)= 1000
End If
Loop Until count1= 8
count1= 0
Do
num1= int(60*Rnd)+1
If num(num1)= 0 then
count1= count1 +1
num(num1)= 5000
End If
Loop Until count1= 4
End Sub