Exceptions
Solar_System API collides!
The purpose of this exercise is to use exceptions, for some original bodies physics.
Question 1
We will start by declaring an exception Bodies_Collision
in
solar_system.adb
.
Question 2
Raise this exception in the Move
procedure when a collision is detected.
Run the code, an exception should be raised soon.
Question 3
Catch this exception in the Move_All
procedure and invert the Speed
of the body when this happens.