Answer:
based on my opinion
The smart guys at NASA designed the trajectory such that as they passed Jupiter, they gained some speed by being dragged along by Jupiter
This is called a gravity assist . Voyager 2 picked up about 18 km / s of velocity from that Jupiter gravity assist ...
Hope this helps