private List<Integer> makePath(Integer start, Integer goal,
                                   Map<Integer, Integer> parent) {

        LinkedList<Integer> list = new LinkedList<>();
        Integer point = goal;
        while (point != null) {
            list.addFirst(point);
            point = parent.get(point);
        }
        return list;
    }
We should use one of the distance calculation according to data
1) Manhattan
2) Euclidean
3) Octile
4) Chebyshev
src/algo/graph/AStar.java