/// <summary> /// Finds the specified state. /// </summary> /// <param name="state">The state.</param> /// <returns>ISuccessor.</returns> public override TSuccessor Find(IAdversarialState state) { Root = new Node(state); var a = state.Player ? Max(Root, double.NegativeInfinity, double.PositiveInfinity) : Min(Root, double.NegativeInfinity, double.PositiveInfinity); return(a.Successor as TSuccessor); }
/// <summary> /// Finds the specified state. /// </summary> /// <param name="state">The state.</param> /// <returns>ISuccessor.</returns> public override TSuccessor Find(IAdversarialState state) { Root = new Node(state); var a = state.Player ? Max(Root) : Min(Root); return((TSuccessor)a.Successor); }
public override ISuccessor Find(IAdversarialState state) { Root = new Node(state); Node a; if (state.Player) a = Max(Root, double.NegativeInfinity, double.PositiveInfinity); else a = Min(Root, double.NegativeInfinity, double.PositiveInfinity); return a.Successor; }
public override ISuccessor Find(IAdversarialState state) { Root = new Node(state); Node a; if (state.Player) a = Max(Root); else a = Min(Root); return a.Successor; }
public override ISuccessor Find(IAdversarialState state) { Root = new Node(state); Node a; if (state.Player) { a = Max(Root, double.NegativeInfinity, double.PositiveInfinity); } else { a = Min(Root, double.NegativeInfinity, double.PositiveInfinity); } return(a.Successor); }
public override ISuccessor Find(IAdversarialState state) { Root = new Node(state); Node a; if (state.Player) { a = Max(Root); } else { a = Min(Root); } return(a.Successor); }
/// <summary> /// Finds the specified state. /// </summary> /// <param name="state">The state.</param> /// <returns>ISuccessor.</returns> public abstract TSuccessor Find(IAdversarialState state);
public abstract ISuccessor Find(IAdversarialState state);