{
    "componentChunkName": "component---src-templates-note-note-js",
    "path": "/notes/Alpha-beta-pruning",
    "result": {"data":{"mdx":{"body":"var _excluded = [\"components\"];\nfunction _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }\nfunction _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }\nfunction _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }\n/* @jsxRuntime classic */\n/* @jsx mdx */\n\nvar _frontmatter = {};\nvar layoutProps = {\n  _frontmatter: _frontmatter\n};\nvar MDXLayout = \"wrapper\";\nreturn function MDXContent(_ref) {\n  var components = _ref.components,\n    props = _objectWithoutProperties(_ref, _excluded);\n  return mdx(MDXLayout, _extends({}, layoutProps, props, {\n    components: components,\n    mdxType: \"MDXLayout\"\n  }), mdx(\"p\", null, \"\", mdx(\"a\", {\n    parentName: \"p\",\n    \"href\": \"/notes/minimax-search\",\n    \"title\": \"minimax search\"\n  }, \"minimax search\"), \"\"), mdx(\"p\", null, \"\", mdx(\"a\", {\n    parentName: \"p\",\n    \"href\": \"/notes/paths-in-a-maze\",\n    \"title\": \"paths in a maze\"\n  }, \"paths in a maze\"), \"\"), mdx(\"p\", null, \"\", mdx(\"a\", {\n    parentName: \"p\",\n    \"href\": \"/notes/game-tree\",\n    \"title\": \"game tree\"\n  }, \"game tree\"), \"\"), mdx(\"p\", null, \"This is the core pruning algorithm inside minimax search.\"), mdx(\"h3\", null, \"\\u2714 Analogy\"), mdx(\"p\", null, \"Instead of checking every path in a maze, you stop exploring a path when you already know it\\u2019s worse than a path you saw earlier.\"), mdx(\"h3\", null, \"\\u2714 Why it matters\"), mdx(\"p\", null, \"It eliminates \", mdx(\"strong\", {\n    parentName: \"p\"\n  }, \"useless branches\"), \" of the game tree.\"), mdx(\"h3\", null, \"\\u2714 What it does\"), mdx(\"ul\", null, mdx(\"li\", {\n    parentName: \"ul\"\n  }, \"Keeps track of best score for maximizing player (\", mdx(\"strong\", {\n    parentName: \"li\"\n  }, \"alpha\"), \")\\n\"), mdx(\"li\", {\n    parentName: \"ul\"\n  }, \"Keeps track of best score for minimizing player (\", mdx(\"strong\", {\n    parentName: \"li\"\n  }, \"beta\"), \")\\n\"), mdx(\"li\", {\n    parentName: \"ul\"\n  }, \"If a branch can\\u2019t possibly improve the outcome \\u2192 \", mdx(\"strong\", {\n    parentName: \"li\"\n  }, \"cut it off\"), \" immediately.\\n\")), mdx(\"h3\", null, \"\\u2714 Example\"), mdx(\"p\", null, \"If Stockfish finds a checkmate in 5 on one branch, it doesn\\u2019t waste time analyzing a losing variation for you.\"));\n}\n;\nMDXContent.isMDXComponent = true;","inboundReferences":[{"id":"f9296a6c-3517-567d-b536-7342843965cf","slug":"stockfish"}]}},"pageContext":{"slug":"Alpha-beta-pruning","node":{"childMdx":{"slug":"Alpha-beta-pruning"}}}},
    "staticQueryHashes": []}