Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6741887
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T11:46:42+00:00 2026-05-26T11:46:42+00:00

I have spent a whole day trying to implement minimax without really understanding it.

  • 0

I have spent a whole day trying to implement minimax without really understanding it. Now, , I think I understand how minimax works, but not alpha-beta pruning.

This is my understanding of minimax:

  1. Generate a list of all possible moves, up until the depth limit.

  2. Evaluate how favorable a game field is for every node on the bottom.

  3. For every node, (starting from the bottom), the score of that node is the highest score of it’s children if the layer is max. If the layer is min, the score of that node is the lowest score of it’s children.

  4. Perform the move that has the highest score if you are trying to max it, or the lowest if you want the min score.

My understanding of alpha-beta pruning is that, if the parent layer is min and your node has a higher score than the minimum score, then you can prune it since it will not affect the result.

However, what I don’t understand is, if you can work out the score of a node, you will need to know the score of all nodes on a layer lower than the node (in my understanding of minimax). Which means that you’llstill be using the same amount of CPU power.

Could anyone please point out what I am getting wrong? This answer ( Minimax explained for an idiot ) helped me understand minimax, but I don’t get how alpha beta pruning would help.

Thank you.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T11:46:42+00:00Added an answer on May 26, 2026 at 11:46 am

    To understand Alpha-Beta, consider the following situation. It’s Whites turn, white is trying to maximize the score, black is trying to minimize the score.

    White evaluates move A,B, and C and finds the best score is 20 with C. Now consider what happens when evaluating move D:

    If white selects move D, we need to consider counter-moves by black. Early on, we find black can capture the white queen, and that subtree gets a MIN score of 5 due to the lost queen. However, we have not considered all of blacks counter-moves. Is it worth checking the rest? No.

    We don’t care if black can get a score lower than 5 because whites move “C” could keep the score to 20. Black will not choose a counter-move with a score higher than 5 because he is trying to MINimize the score and has already found move with a score of 5. For white, move C is preferred over move D as soon as the MIN for D (5 so far) goes below that of C (20 for sure). So we “prune” the rest of the tree there, pop back up a level and evaluate white moves E,F,G,H…. to the end.

    Hope that helps.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have spent the whole day trying to make my application use threads but
I have spent the whole day trying to make a script which on submit
I have spent most of a day trying to understand why Java cannot compile
I've spent the whole day googling and deleting and inserting trying to implement this
Ok, I have just spent the whole day playing with DomDocument and creating some
This must be a very stupid newbie question, but I have spent my whole
I've spent over a day trying to figure this out, I have looked at
I have spent several hours trying to find a means of writing a cross
I have spent too much time on this problem and am beginning to think
I have spent the afternoon trying to wrap my mind around how to translate

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.