The minimax algorithm is a depth-based algorithm that explores possible future decisions and ranks each decision's maximal or minimal effect, allowing for optimal decisions. The alpha beta pruning technique, when used in conjunction with the minimax algorithm, allows for more efficient tree traversal when it is not possible for any further depth-searching along the current path to affect the outcome of the decision/rank.
Below is my implementation of the minimax algorithm along with alpha and beta pruning functionality. For context, full source code is at the bottom.
Below is the full source code. For this school assignment, the pygame source code minus the minimax and alphabeta pruning code was provided by UCSB instructors and I claim no credit for it's creation.