Question: An android application that will get the user's guess number and will be compared to the computers' random rolled dice. At the start of the

An android application that will get the user's guess number and will be compared to the computers' random rolled dice. At the start of the game, the user has a 20-point credit.

If the guess is correct then a 5-point credit will be added to the user's remaining credit If the guess is wrong then a 5-point credit will be deducted to the user's remaining credit


REQUIREMENT: You need to create 1 Activity and 2 fragments for this challenge. The Main Activity, the "Guess" fragment and "Result" fragment. You also need "Dice class". Your Dice class MUST HAVE the following method signature


 ALSO PROVIDE THE PROJECT FILE 




Dice class rollDice(Image View img1, Image View img2) void getRemainingCredits() int Thefirst figure shows the starting Activity. The user has a starting creditof 20. Dice Roll Game Starting Credits 20 ROLL DICE AGAIN Enter

Dice class rollDice(Image View img1, Image View img2) void getRemainingCredits() int The first figure shows the starting Activity. The user has a starting credit of 20. Dice Roll Game Starting Credits 20 ROLL DICE AGAIN Enter your guess here ROLL DICE After placing the users' guess number, the user may roll the dice. Clicking the "Roll dice" button will change the fragment to "Result" fragment. Clicking "Roll dice again" button will change the fragment to "Guess" fragment.

Step by Step Solution

3.40 Rating (159 Votes )

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

To fulfill your requirements you can create an Android application with the following structure Main ... View full answer

blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!