Beispiel #1
0
 private void ChangeLocation(int iterator)
 {
     _visited.Add(_currentLocation.Neighbors[iterator]);
     _lengthOfRoad   += _currentLocation.Neighbors[iterator].Cost;
     _currentLocation = _currentLocation == _currentLocation.Neighbors[iterator].FirstNode
         ? _currentLocation.Neighbors[iterator].SecondNode
         : _currentLocation.Neighbors[iterator].FirstNode;
     _probabilities = FindWay();
 }
Beispiel #2
0
 private void AddEdge(int value)
 {
     _edges.Add(new Edge(value));
 }