Completed

I need a Java developer

The project to be completed is programming a simplified version of the dice game "shut the box".

Game preparation

Eight boxes (from 1 to 8) are numbered.

Game Play

In each round, players 1 and 2 play in succession. The player rolls two dice and calculates the sum of the rolled numbers. Now he has to choose a combination of two open boxes, the sum of which is equal to the rolled sum. For example, if he rolled 4 + 4 = 8 with the two dice, he can close boxes 1 and 7 (because 1 + 7 = 8) if they are still open. Afterwards the selected boxes are closed. If such a choice of the boxes is not possible, then the player is credited the sum of all still open boxes to his points account. An automatic check of all possibilities to determine if there is at least one valid combination is not necessary.

Playing

In total, eight rounds are played. In a round, both players are on the turn. The player with the fewest points wins the game. If a player manages to close the last box before the end of the eight rounds, he immediately wins the game, regardless of the previous points.

Programming restrictions

The method dice () from MiniJava returns the result of a cube dice. Use this method to simulate a dice. Use readInt () from MiniJava to read integers. Use the method outputBoxes (boolean [] boxes) to output which boxes are still open.

If the player is to enter a combination for the diced number, the prompt is repeated if the sum of the entry is incorrect or the box for that number is already closed. If the player believes that there is no valid combination, he can count the points by entering 0 and then it's the other player's turn. Both cases are only checked after entering both boxes. If one of the two entries is 0, the points will be counted.

The output format can be seen in the example versions, as well as the last issue, of course, a "draw!" give (see attached file).

Do not implement any other classes or methods for this task. Only arrays, basic types and strings are allowed as data types, as imports only packages from java.lang. *.

Skills: Java, Javascript

See more: how can i find java developer, i have an idea i need a developer, i need a developer for free, i need a developer for ipage, i need a developer for my idea, i need a developer to put my game on apple, i need a developer who can help me develop my app, i need a developer who have good experience in woo-commerce and wordpress, i need a developer who have good experience in woocommerce and wordpress, i need a developer, i need application developer, i need mvc developer in delhi, i need php developer in chennai, i need qlikview developer as part time in india, i need software developer in goa, i need someone to do some data entry, i need web developer for part time, i need web developer in india to call me, need java developer, i need java programmer in hyderabad

About the Employer:
( 0 reviews ) Bad Nauheim, Germany

Project ID: #22219050

Awarded to:

ThinkAndCo

Hi, We are a team of professional software developers. We have expertise in Java and can readily work on your task. Kindly consider our proposal for the best results. Looking forward to talking for more information. More

€30 EUR in 1 day
(38 Reviews)
4.7

3 freelancers are bidding on average €26 for this job

Jng93Slv3

Hi! I'm interesting your project very well. I am good at Java and I'm a good Engineer. And also I have many experience and good skill about algorithm development. I have top rank in hackerrank online competitions whic More

€30 EUR in 1 day
(9 Reviews)
4.4
gjiki98

Hi there, I’d like to be considered for writing your project. I have working experience in Algorithms(Advanced Level), Data Structures, Object Oriented Programming, AI, Machine Learning, Desktop Development, OS, Androi More

€19 EUR in 1 day
(4 Reviews)
2.0