Question: Please write the program in C++ . Problem : Implement the minimax(max value function and min value funtion) tree to do both alpha and beta

Please write the program in C++. Problem: Implement the minimax(max value function and min value funtion) tree to do both alpha and beta pruning according to link(https://en.wikipedia.org/wiki/Alphabeta_pruning) and print a message "alpha pruning" or "beta pruning" each time that occurs (in addition to the max of the tree). For example, the inputted tree: ((3,8,(7,(3,0,7),(8,8,2))), (4,(7,9,8),8), (((3,6,4),2,6),((9,2,9),4,7,(6,4,5) ),4,(6,4,5))) would print "alpha pruning" 3 times and "beta pruning" 3 times. 

A visual representation of the tree inputted above is:

Please write the program in C++. Problem: Implement the minimax(max value function

A visual representation of the tree minmax alpha beta complete of input above is:

and min value funtion) tree to do both alpha and beta pruning

So then once the program is done its output should be printed: "alpha pruning" 3 times and "beta pruning" 3 times.

If you have any more question, then let me know, thanks.

p.s. IF YOU can do the above problem in PYTHON, then please do so and comment it and provide good identions on here.

Max Min Max 4 4 2) (6 4) (7 6 Max Min Max 4 4 2) (6 4) (7 6

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!