You are assigned a new space mission, where you have to destroy certain galaxies ruled by Luxtoro and Turtoro (random villains). The galaxies consist of D and H number of planets and you are provided...


You are assigned a new space mission, where you have to destroy certain galaxies ruled<br>by Luxtoro and Turtoro (random villains). The galaxies consist of D and H number of<br>planets and you are provided with only two special weapons:<br>One destroys exactly one planet from both the galaxies simultaneously.<br>The other cuts in half each planet from one galaxy of your choice and in effect<br>doubles the number of planets.<br>You have to develop a python code to find whether it's possible to destroy both the<br>galaxies and print the minimum number of gun firings required as the output.<br>Sample Input:<br>1<br>26<br>Sample Output:<br>8<br>

Extracted text: You are assigned a new space mission, where you have to destroy certain galaxies ruled by Luxtoro and Turtoro (random villains). The galaxies consist of D and H number of planets and you are provided with only two special weapons: One destroys exactly one planet from both the galaxies simultaneously. The other cuts in half each planet from one galaxy of your choice and in effect doubles the number of planets. You have to develop a python code to find whether it's possible to destroy both the galaxies and print the minimum number of gun firings required as the output. Sample Input: 1 26 Sample Output: 8

Jun 08, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here