Assignment: Slot machine Simulation
Learning Objectives:
To decide which loop structures to use, such as while, do while, and for loop in Java.
To use decision structures such as if, if-else, and switch statements in Java
To use file input and output to read data from a file and write data to a file.
To generate random numbers with the Random class.
To write your own testing cases to test your program.
To use debugger for debugging your Java program.
Problem Statement
A slot machine is a gambling device that the user inserts money into and then pulls a lever or push a button. The slot machine then displays a set of random images. If two or more of the images match, the user wins an amount of money that the slot machine dispenses back to the user.
Create a program that simulates a slot machine.