Computer Science, asked by PrasanthsaiKolli, 1 day ago

Hari was forced to participate in a game where he is up against an opponent, Ram. Both choose a random number. Suppose Hari chose X and Ram chose Y. The number of turns is given by the referee. Whenever the turn number is odd, X is multiplied by 2 and if the turn number is even, Y is multiplied by 2. The task is to find the value of max(Finalx, FinalY)/min(FinalX, Finaly) after they complete P turns. Given three positive integers X, Y and P, where P denotes the number of turns, find the value after P turns. Example 1 Input 1 2 3 Output 1​

Answers

Answered by Yuhanji
1

Answer:

Did you mean: Hari was forced to participate in a game where he is up against an opponent, Ram. Both choose a random number. Suppose Hari chose X and Ram chose Y. The number of turns is given by the referee. Whenever the turn number is odd, X is multiplied by 2 and if the turn number is even, Y is multiplied by 2. The task is to find the value of max(Final, FinallY)/min(Final, Finally) after they complete P turns. Given three positive integers X, Y and P, where P denotes the number of turns, find the value after P turns. Example 1 Input 1 2 3 Output 1

Similar questions