Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

How can i solve this question from beecrowd problem 3037 in java without using arrays: John and Mary created their own version of darts, darts

How can i solve this question from beecrowd problem 3037 in java without using arrays:

John and Mary created their own version of darts, darts by distance. Each one throws 3 darts, choosing how far they will play from the target. In the normal game of darts, a number x is scored by the distance between where the dart hit and the center of the target. In the game of John and Mary it is punctuated xd where d is the distance betwen the shooter and the target.

John asks you to make an algorithm that gives the score given the distance of each turn, returns the winner

Input

The first line of the entry consists of a N number of test cases. In each test case there will be 6 lines, where the first 3 lines correspond to the pitches of John and the next 3 lines to the pitches of Mary. Each line of a test case consists of two numbers X and D where X is the score and D is the distance

Output

The output consists of the winner of each test case.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Big Data, Mining, And Analytics Components Of Strategic Decision Making

Authors: Stephan Kudyba

1st Edition

1466568704, 9781466568709

More Books

Students also viewed these Databases questions

Question

Why is using UML for modeling important?

Answered: 1 week ago

Question

7.3 Describe considerations in the preliminary applicant screening.

Answered: 1 week ago