Ejemplo n.º 1
0
        public void BestMove()
        {
            int lBoardSize = 9;
            MoveList lMoveList = new MoveList(lBoardSize);

            lMoveList.Add(CoordinateSystem.AtFromSGF("C4", lBoardSize), 4);
            lMoveList.Add(CoordinateSystem.AtFromSGF("A6", lBoardSize), 6);
            lMoveList.Add(CoordinateSystem.AtFromSGF("A5", lBoardSize), 5);
            lMoveList.Add(CoordinateSystem.AtFromSGF("E1", lBoardSize), 7);
            lMoveList.Add(CoordinateSystem.AtFromSGF("A3", lBoardSize), 3);
            lMoveList.Add(CoordinateSystem.AtFromSGF("D2", lBoardSize), 2);

            Assert.AreEqual(CoordinateSystem.AtFromSGF("E1", lBoardSize), lMoveList.GetBestMove());
            lMoveList.QuickSort();
        }
Ejemplo n.º 2
0
		public void BestMove()
		{
			int lBoardSize = 9;
			MoveList lMoveList = new MoveList(lBoardSize);

			lMoveList.Add(CoordinateSystem.AtFromSGF("C4", lBoardSize), 4);
			lMoveList.Add(CoordinateSystem.AtFromSGF("A6", lBoardSize), 6);
			lMoveList.Add(CoordinateSystem.AtFromSGF("A5", lBoardSize), 5);
			lMoveList.Add(CoordinateSystem.AtFromSGF("E1", lBoardSize), 7);
			lMoveList.Add(CoordinateSystem.AtFromSGF("A3", lBoardSize), 3);
			lMoveList.Add(CoordinateSystem.AtFromSGF("D2", lBoardSize), 2);

			Assert.AreEqual(CoordinateSystem.AtFromSGF("E1", lBoardSize), lMoveList.GetBestMove());
			lMoveList.QuickSort();

		}
Ejemplo n.º 3
0
 /// <summary>
 /// Sorts the move list.
 /// </summary>
 /// <param name="moves">The moves.</param>
 /// <returns></returns>
 public void SortMoveList(MoveList moves)
 {
     moves.QuickSort();
 }
Ejemplo n.º 4
0
 /// <summary>
 /// Sorts the move list.
 /// </summary>
 /// <param name="moves">The moves.</param>
 /// <returns></returns>
 public void SortMoveList(MoveList moves)
 {
     moves.QuickSort();
 }