Skip to content

Commit 43b5cb9

Browse files
authored
Typos at search.ipynb (#1179)
1 parent dae3e4d commit 43b5cb9

File tree

1 file changed

+15
-4
lines changed

1 file changed

+15
-4
lines changed

search.ipynb

+15-4
Original file line numberDiff line numberDiff line change
@@ -1623,7 +1623,7 @@
16231623
" elif limit >= 0:\n",
16241624
" cutoff_occurred = True\n",
16251625
" limit += 1\n",
1626-
" all_node_color.pop()\n",
1626+
" all_node_colors.pop()\n",
16271627
" iterations -= 1\n",
16281628
" node_colors[node.state] = \"gray\"\n",
16291629
"\n",
@@ -2162,6 +2162,8 @@
21622162
"outputs": [],
21632163
"source": [
21642164
"# Heuristics for 8 Puzzle Problem\n",
2165+
"import math\n",
2166+
"\n",
21652167
"def linear(node):\n",
21662168
" return sum([1 if node.state[i] != goal[i] else 0 for i in range(8)])\n",
21672169
"\n",
@@ -2853,7 +2855,7 @@
28532855
" neighbor = argmax_random_tie(neighbors,\n",
28542856
" key=lambda node: problem.value(node.state))\n",
28552857
" if problem.value(neighbor.state) <= problem.value(current.state):\n",
2856-
" \"\"\"Note that it is based on negative path cost method\"\"\"\n",
2858+
" \"\"\"Note that it is based on negative path cost method\"\"\"\n",
28572859
" current.state = neighbor.state\n",
28582860
" iterations -= 1\n",
28592861
" \n",
@@ -6527,7 +6529,7 @@
65276529
"name": "python",
65286530
"nbconvert_exporter": "python",
65296531
"pygments_lexer": "ipython3",
6530-
"version": "3.6.4"
6532+
"version": "3.7.6"
65316533
},
65326534
"widgets": {
65336535
"state": {
@@ -6561,8 +6563,17 @@
65616563
}
65626564
},
65636565
"version": "1.2.0"
6566+
},
6567+
"pycharm": {
6568+
"stem_cell": {
6569+
"cell_type": "raw",
6570+
"source": [],
6571+
"metadata": {
6572+
"collapsed": false
6573+
}
6574+
}
65646575
}
65656576
},
65666577
"nbformat": 4,
65676578
"nbformat_minor": 1
6568-
}
6579+
}

0 commit comments

Comments
 (0)