Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Can You Guess the Guest? Bibi is celebrating her 2 1 st birthday party. She invites you and another 5 friends to join the party.
Can You Guess the Guest?
Bibi is celebrating her st birthday party. She invites you and another friends to join the party. Lucky to you and her friends, you will get a private room to enjoy the party with Bibi.
Bibi decided to play with her friends except you because Bibi wants your help. Her friends those five friends will think of a random number M; Then, Bibi will give them some pieces of blank paper.
Firstly, the ith person should add his her chosen number M; with M; itself and then write the result on the blank paper.
Then, they should put the paper they wrote before to
Bibi's bag. Then, Bibi ask them to shake each other's hands. If ith person shake hands with ith person, then both of ith and th person should write M; M; in their paper and put the paper into the bag. This procedure stops when everyone already shakes each other's hands.
After that, Bibi should guess the possible numbers that her friends just think about.You should help Bibi to determine those numbers. It is guaranteed that the solution exists and unique.
Format Input
Input consists of one integer T number of test case given by Bibi. For each test case, there is a line with integers S the addition result written by her friends sum of M; and M; for every possible i and j
Format Output
Output should be expressed in format "Case #X: Y Y Y Y Ys X is the number of the test case starting from and followed by integer Y the numbers in nondecreasing
Constraints
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started