Home > Software engineering > For help! Using VB to write a simple flies games, but hit a number of problems
For help! Using VB to write a simple flies games, but hit a number of problems
Time:10-02
Writing is such, so hit three flies is respectively recorded the number of times, how to let it recorded a total of the number of times?
CodePudding user response:
Option Explicit Private Cy (3) As an Integer Private Sub Image1_Click (Index As an Integer) Cy (Index)=Cy (Index) + 1 'single number Print "you hit a fly & amp;" The Index & amp; "Total" & amp; Cy (Index) & amp; "Time!" Cy (3)=Cy (3) the total number of + 1 'cumulative Print "you hit the flies" & amp; Cy (3) & amp; "Time!" End Sub