Inteligentna_smieciarka/heuristicfn.py

3 lines
100 B
Python
Raw Normal View History

def heuristicfn(startx, starty, goalx, goaly):
return abs(startx - goalx) + abs(starty - goaly)