コード例 #1
0
 public Ant(Anthill hill, int antValueName)
 {
     _hill            = hill;
     _currentLocation = hill.CurrentLocation;
     _antValueName    = antValueName;
     _visited         = new ListOfEdges();
     _random          = new Random(_antValueName);
 }
コード例 #2
0
ファイル: Graph.cs プロジェクト: Rhenin/AntColony
 public Graph(int size)
 {
     _nodes     = new ListOfNodes();
     _edges     = new ListOfEdges();
     _graphSize = size;
     GraphGenerate();
     _nodes.FindByValue(30).Food = true;
     _nodes.FindByValue(36).Food = true;
 }
コード例 #3
0
 public GraphNode(int value)
 {
     Value     = value;
     Neighbors = new ListOfEdges();
 }