Using the Die class, write an application that randomly “throws” five dice for the computer and five dice for the player. Display the values and then, by observing the results, decide who wins based on the following hierarchy of Die values. (The computer will not decide the winner; the player will determine the winner based on observation.) Any higher combination beats a lower one; for example, five of a kind beats four of a kind.
. Five of a kind
. Four of a kind
.Three of a kind
.A pair
After you learn about decision making in the next chapter, you will be able to make the program determine whether you or the computer had the better roll, and after you read the chapter Arrays, you will be able to make the determination more efficient. For now, just observe how the values change as you execute the program multiple times. Save the application as FiveDice.java.
We need at least 10 more requests to produce the solution.
0 / 10 have requested this problem solution
The more requests, the faster the answer.