結果 : shortest distance finding algorithm