Question: write in pseudocode 2) An astronomy application displays information about the eight planets in our solar system. Write the logic for this application in pseudocode:

write in pseudocode

2) An astronomy application displays information about the eight planets in our solar system. Write the logic for this application in pseudocode:

a. Visit this web page: https://space-facts.com/planets/

b. Note down each planets name, distance from the sun, and diameter

c. Write the program such that it:

i. Displays a numbered list of the planets that includes

1. Planet number (1 is the planet closest to the sun and 8 is the one farthest from it)

2. Planets name

3. Distance from the sun

4. Diameter

Here is a sample of the required format of output: Planet #1: Mercury is 36 million miles from the sun and has a diameter of 3031 miles

ii. Allows the user to enter the number of any planet, and displays output similar to that shown above, for that planet, e.g., if the user entered 1, the output would be the sentence shown above. If the user enters an invalid planet number, such as zero or 9, the program must display an error message

iii. Allows the user to enter the numbers of any two planets, and outputs both their names as well as their distance from each other. If the user enters an invalid planet number, such as zero or 9, the program must display an error message

Note: (ii) and (iii) above must be accomplished without any search being performed

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!