Fix #13, PEP8-ify notebooks.

This commit is contained in:
Donne Martin
2015-07-11 15:34:52 -04:00
parent 374d67ff30
commit 04083b2011
25 changed files with 210 additions and 173 deletions

View File

@@ -34,7 +34,6 @@
"source": [
"## Constraints\n",
"\n",
"* Do you expect the return to be in reverse order too?\n",
" * Yes\n",
"* What if one of the inputs is None?\n",
@@ -98,7 +97,7 @@
"outputs": [],
"source": [
"class MyLinkedList(LinkedList):\n",
" \n",
"\n",
" def add_reverse(self, first_list, second_list):\n",
" # TODO: Implement me\n",
" pass"
@@ -133,7 +132,7 @@
"\n",
"\n",
"class TestAddReverse(object):\n",
" \n",
"\n",
" def test_add_reverse(self):\n",
" print('Test: Empty list(s)')\n",
" assert_equal(MyLinkedList().add_reverse(None, None), None)\n",
@@ -166,13 +165,15 @@
" second_list.append(7)\n",
" result = MyLinkedList().add_reverse(first_list, second_list)\n",
" assert_equal(result.get_all_data(), [5, 4, 2, 1])\n",
" \n",
"\n",
" print('Success: test_add_reverse')\n",
"\n",
"\n",
"def main():\n",
" test = TestAddReverse()\n",
" test.test_add_reverse()\n",
"\n",
"\n",
"if __name__ == '__main__':\n",
" main()"
]