title: How to draw shortest path between two locations
body: <p><strong>How can I show shortest path in my code like it is in the picture?</strong>
  <img src="https://i.stack.imgur.com/hqFBb.png" alt="enter image description here"></p>
  
  <p>I'm using this code to find shortest distance between two points.</p>
  
  <pre><code>Location locationA = new Location("point A");
  
  locationA.setLatitude(lat);
  locationA.setLongitude(long);
  
  Location locationB = new Location("point B");
  
  locationB.setLatitude(lat);
  locationB.setLongitude(long);
  
  distance = locationA.distanceTo(locationB);
  </code></pre>