What is the purpose or problem that the program is trying to solve?
The purpose of this program is for a person or a player to play against the computer in a virtual game of “Rock Paper Scissors”. There are no levels of difficulty.
Algorithm Outlining the Program
Explanation of Data Types used
(What types are used in the variables in your program and where ? Remember the DIM statement)
Text- The text variables used in my program is first of all, the text of the radiobutton to clearly identify what options there are (rock paper scissor). The text used to state or give some form of title in the object of the group box (eenie meanie miney mo). The text used on three of the buttons to identify what exactly the button does. (Go!
Don’t know how to play? Click here.
Click to exit.) The text used in the label to clearly notify the player on which weapon the computer chose and whether the player won, lost or if it was draw. Lastly, the text used in the other label to simply state how to play the game.
Integer- The integer used in my program was “DIM number As Integer”. The purpose of this is to have rock paper or scissor as an integer or whole number, either 1, 2 or 3. This then allows the machine to choose randomly using the commands of “Randomize()” and “number=(3*())” and therefore choosing it’s weapon to be used against the player.
Control Structure examples
(copy and paste the appropriate section from your program and explain)
Sequence: Firstly, the (human) player must choose their desired weapon (either rock, paper or scissor), by selecting one of the radiobuttons beside the particular weapon. Then in order for somthing to happen, the player must then click the “Go!” button. This will then motion the machine to choose a number randomly in which is allocated to specifically either rock paper or scissor. Once this happens, the label will then clearly indicate the outcome in which what the computer player has chosen and whether the human player has either won, lost or drawed agains the computer player.
Selection: choosing either “rock” “paper” or “scissor” as your or the computer’s desired weapon as it uses the “If” statements.
Repetition: n/a
Use of Error Detection
(explain how your program handles incorrect user inputs)
My program detects the incorrect user outputs by simply having no access for the user to type anything. Just simply using the mouse and clicking away. This therefore makes it easy to not have any incorrect outputs.

No comments:
Post a Comment