Asteroid Size Estimator A scientific research team is trying to study asteroids sizes

Asteroid Size Estimator

A scientific research team is trying to study asteroids sizes in the space to assess the impact of collision on earth. It is not possible size of the asteroid. Hence, they provided the relation of one asteroid size with another one. Given the relative size comparisons in equation, your task is to come up with a program which generates an output with relationship with all the asteroids found. Arrange size in descending order.
Develop a program to help the research team convert the input specification to standardized output specification. Your program is the relations data as input and produce an output as per corresponding output specification as output.
Please note: Custom input option is not available for this question.
Sample Input# 1:
A,C,D,E
E=5 A
C=2 D
D=100 E
code in java or c++​

Related Posts

Leave a Reply

Your email address will not be published. Required fields are marked *