Skip to content

Commit 9a748cc

Browse files
committed
Fixing or Removing Broken Links
1 parent 9013772 commit 9a748cc

File tree

7 files changed

+29
-39
lines changed

7 files changed

+29
-39
lines changed

01_slides/1_motivation_big_o.ipynb

+1-1
Original file line numberDiff line numberDiff line change
@@ -390,7 +390,7 @@
390390
"Here are seven Big-O run times that you’ll encounter frequently, sorted\n",
391391
"from fasted to slowest.\n",
392392
"\n",
393-
"![](attachment:images/big_o_viz.jpg)\n",
393+
"![](./images/big_o_viz.jpg)\n",
394394
"\n",
395395
"- $O(1)$, known as *constant time*. Ex: addition, division\n",
396396
"\n",

01_slides/2_ds_search_sort.ipynb

+1-1
Original file line numberDiff line numberDiff line change
@@ -226,7 +226,7 @@
226226
"- You need to traverse the list once for each item in the list, so the\n",
227227
" Big-O is $O(n^2)$.\n",
228228
"\n",
229-
"![](attachment:images/insertion_sort.png)\n",
229+
"![](./images/insertion_sort.png)\n",
230230
"\n",
231231
"## Live Coding:\n",
232232
"\n",

01_slides/3_recursion.ipynb

+5-5
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@
7474
"- Suppose you are looking for a key in a box, but the box contains\n",
7575
" more boxes!\n",
7676
"\n",
77-
"![](attachment:images/box_recursion.png)\n",
77+
"![](./images/box_recursion.png)\n",
7878
"\n",
7979
"- 2 minutes: write down the steps of the algorithm you would take to\n",
8080
" search for the key\n",
@@ -224,15 +224,15 @@
224224
"\n",
225225
"## Recursion and the Call Stack\n",
226226
"\n",
227-
"![](attachment:images/rec_call_1.png)\n",
227+
"![](./images/rec_call_1.png)\n",
228228
"\n",
229229
"## Recursion and the Call Stack\n",
230230
"\n",
231-
"![](attachment:images/rec_call_2.png)\n",
231+
"![](./images/rec_call_2.png)\n",
232232
"\n",
233233
"## Recursion and the Call Stack\n",
234234
"\n",
235-
"![](attachment:images/rec_call_3.png)\n",
235+
"![](./images/rec_call_3.png)\n",
236236
"\n",
237237
"## Multiple Recursive Calls: Fibonacci Sequence\n",
238238
"\n",
@@ -489,7 +489,7 @@
489489
"- Python’s sort function uses a hybrid of merge and insertion sort,\n",
490490
" both of which you’ve learned!\n",
491491
"\n",
492-
"![](attachment:images/merge_sort.png)\n",
492+
"![](./images/merge_sort.png)\n",
493493
"\n",
494494
"## Big-O of Merge Sort\n",
495495
"\n",

01_slides/4_recursive_ds.ipynb

+17-17
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@
5454
"- The *height* of a tree is the longest path from its root to its\n",
5555
" leaves. The height of this tree is 4\n",
5656
"\n",
57-
"![](attachment:images/tree.png)\n",
57+
"![](./images/tree.png)\n",
5858
"\n",
5959
"## Anatomy of a Tree\n",
6060
"\n",
@@ -70,7 +70,7 @@
7070
"- The *ancestors* of a value are its parent, the parent of its parent,\n",
7171
" etc.\n",
7272
"\n",
73-
"![](attachment:images/tree.png)\n",
73+
"![](./images/tree.png)\n",
7474
"\n",
7575
"## Tree Traversal Methods\n",
7676
"\n",
@@ -97,7 +97,7 @@
9797
"\n",
9898
"**Result: 4 2 5 1 6 3**\n",
9999
"\n",
100-
"![](attachment:images/tree_num.png)\n",
100+
"![](./images/tree_num.png)\n",
101101
"\n",
102102
"## DFS: Inorder Traversal Code\n",
103103
"\n",
@@ -201,7 +201,7 @@
201201
"\n",
202202
"Preorder traversal is used to create a copy of the tree\n",
203203
"\n",
204-
"![](attachment:images/tree_num.png)\n",
204+
"![](./images/tree_num.png)\n",
205205
"\n",
206206
"## DFS: Postorder Traversal\n",
207207
"\n",
@@ -215,7 +215,7 @@
215215
"\n",
216216
"Preorder traversal is used to delete subtrees. (why?)\n",
217217
"\n",
218-
"![](attachment:images/tree_num.png)\n",
218+
"![](./images/tree_num.png)\n",
219219
"\n",
220220
"## BFS\n",
221221
"\n",
@@ -236,7 +236,7 @@
236236
"\n",
237237
"**Result: 1 2 3 4 5 6**\n",
238238
"\n",
239-
"![](attachment:images/tree_num.png)\n",
239+
"![](./images/tree_num.png)\n",
240240
"\n",
241241
"# Binary Search Trees\n",
242242
"\n",
@@ -269,7 +269,7 @@
269269
"\n",
270270
" - So if the tree was balanced, then it would be $O(\\text{log}n)$\n",
271271
"\n",
272-
"![](attachment:images/tree_unbal.png)\n",
272+
"![](./images/tree_unbal.png)\n",
273273
"\n",
274274
"## BST Efficiency\n",
275275
"\n",
@@ -287,7 +287,7 @@
287287
"\n",
288288
"Given a BST, insert a new node in this BST.\n",
289289
"\n",
290-
"![](attachment:images/insertion.png)\n"
290+
"![](./images/insertion.png)\n"
291291
]
292292
},
293293
{
@@ -321,7 +321,7 @@
321321
"\n",
322322
" - A node connected to another is a *neighbor*\n",
323323
"\n",
324-
"![](attachment:images/graph_anat.png)\n",
324+
"![](./images/graph_anat.png)\n",
325325
"\n",
326326
"## Types of Graphs\n",
327327
"\n",
@@ -341,7 +341,7 @@
341341
"There are two questions we ask about graphs: Is there a path from node A\n",
342342
"to B? What is the shortest path from node A to B? BFS answers both!\n",
343343
"\n",
344-
"![](attachment:images/graph_weight.png)\n",
344+
"![](./images/graph_weight.png)\n",
345345
"\n",
346346
"## BFS of Graphs\n",
347347
"\n",
@@ -376,7 +376,7 @@
376376
"\n",
377377
"Queue: \\[ , , , , \\]\n",
378378
"\n",
379-
"![](attachment:images/graph_bfs.png)\n",
379+
"![](./images/graph_bfs.png)\n",
380380
"\n",
381381
"## BFS Example\n",
382382
"\n",
@@ -387,7 +387,7 @@
387387
"\n",
388388
"Queue: \\[1, , , , \\]\n",
389389
"\n",
390-
"![](attachment:images/graph_bfs.png)\n",
390+
"![](./images/graph_bfs.png)\n",
391391
"\n",
392392
"## BFS Example\n",
393393
"\n",
@@ -402,7 +402,7 @@
402402
"\n",
403403
"Queue: \\[3, 6, , , \\]\n",
404404
"\n",
405-
"![](attachment:images/graph_bfs.png)\n",
405+
"![](./images/graph_bfs.png)\n",
406406
"\n",
407407
"## BFS Example\n",
408408
"\n",
@@ -414,7 +414,7 @@
414414
"\n",
415415
"Queue: \\[6, 10, , \\]\n",
416416
"\n",
417-
"![](attachment:images/graph_bfs.png)\n",
417+
"![](./images/graph_bfs.png)\n",
418418
"\n",
419419
"## BFS Example\n",
420420
"\n",
@@ -426,7 +426,7 @@
426426
"\n",
427427
"Queue: \\[10, 7, , \\]\n",
428428
"\n",
429-
"![](attachment:images/graph_bfs.png)\n",
429+
"![](./images/graph_bfs.png)\n",
430430
"\n",
431431
"## BFS Example\n",
432432
"\n",
@@ -439,7 +439,7 @@
439439
"\n",
440440
"Queue: \\[7, , , , \\]\n",
441441
"\n",
442-
"![](attachment:images/graph_bfs.png)\n",
442+
"![](./images/graph_bfs.png)\n",
443443
"\n",
444444
"## BFS Example\n",
445445
"\n",
@@ -451,7 +451,7 @@
451451
"\n",
452452
"Queue: \\[ , , , , \\]\n",
453453
"\n",
454-
"![](attachment:images/graph_bfs.png)\n",
454+
"![](./images/graph_bfs.png)\n",
455455
"\n",
456456
"## Time and Space Complexity of BFS\n",
457457
"\n",

02_assignments/assignment_1.ipynb

+5-5
Original file line numberDiff line numberDiff line change
@@ -43,23 +43,23 @@
4343
"\n",
4444
" ### Example 1\n",
4545
"\n",
46-
" ![](images/q1_ex1.png \"Example 1\")\n",
46+
" ![](./images/q1_ex1.png)\n",
4747
"\n",
4848
" Input: `root = [1, 2, 2, 3, 5, 6, 7]` *What traversal method is this?*\n",
4949
"\n",
5050
" Output: 2\n",
5151
"\n",
5252
" ### Example 2\n",
5353
"\n",
54-
" ![](images/q1_ex2.png \"Example 2\")\n",
54+
" ![](./images/q1_ex2.png)\n",
5555
"\n",
5656
" Input: `root = [1, 10, 2, 3, 10, 12, 12]`\n",
5757
"\n",
5858
" Output: 10\n",
5959
"\n",
6060
" ### Example 3\n",
6161
"\n",
62-
" ![](images/q1_ex3.png \"Example 3\")\n",
62+
" ![](./images/q1_ex3.png)\n",
6363
"\n",
6464
" Input: `root = [10, 9, 8, 7]`\n",
6565
"\n",
@@ -101,15 +101,15 @@
101101
"\n",
102102
" ### Example 1\n",
103103
"\n",
104-
" ![](images/q1_ex1.png \"Example 1\")\n",
104+
" ![](./images/q1_ex1.png)\n",
105105
"\n",
106106
" Input: `root = [1, 2, 2, 3, 5, 6, 7]` *What traversal method is this?*\n",
107107
"\n",
108108
" Output: [[1, 2, 3], [1, 2, 5], [1, 2, 6], [1, 2, 7]]\n",
109109
"\n",
110110
" ### Example 2\n",
111111
"\n",
112-
" ![](images/q1_ex3.png \"Example 2\")\n",
112+
" ![](./images/q1_ex3.png)\n",
113113
"\n",
114114
" Input: `root = [10, 9, 8, 7]`\n",
115115
"\n",

05_cohort_three/additional_resources/lessons/5_optimization.ipynb

-8
Original file line numberDiff line numberDiff line change
@@ -212,31 +212,23 @@
212212
"- For cell Guitar 1, a guitar will fit there. It will also fit in cell Guitar 2, 3, 4\n",
213213
"- Sounds redundant, but let's keep going\n",
214214
"\n",
215-
"![](images/dynamic.png)\n",
216-
"\n",
217215
"## Stereo Row\n",
218216
"\n",
219217
"- In the second row, we can steal the stereo or the guitar.\n",
220218
"- At 1 kg, you can only steal the guitar, same as for every other cell until Stereo 4, at which point you can steal the stereo and only the stereo.\n",
221219
"\n",
222-
"![](images/dynamic.png)\n",
223-
"\n",
224220
"## Laptop Row\n",
225221
"\n",
226222
"- Now we can steal all 3 items\n",
227223
"- In the first two columns, we still can only steal the guitar. But in Laptop 3, we can steal the laptop\n",
228224
"- Laptop 4 is the interesting step. We could steal only the stereo, or the laptop and something else for 1 kg. What is that 1 kg item?\n",
229225
"- According to the above row, the max value for 1 kg is the guitar!\n",
230226
"\n",
231-
"![](images/dynamic.png)\n",
232-
"\n",
233227
"## Solution\n",
234228
"\n",
235229
"- If we stole the guitar and laptop, the total value is 3500, which is greater than just stealing the stereo\n",
236230
"- Thus, we should steal guitar and laptop\n",
237231
"\n",
238-
"![](images/dynamic.png)\n",
239-
"\n",
240232
"## Formula for each cell\n",
241233
"\n",
242234
"- We skipped some very trivial steps in calculating cells aside from the last one\n",

05_cohort_three/additional_resources/lessons/6_slow_code.ipynb

-2
Original file line numberDiff line numberDiff line change
@@ -68,8 +68,6 @@
6868
"- Memoization can also avoid the maximum recursion depth error because\n",
6969
" the call stack is smaller\n",
7070
"\n",
71-
"![](attachment:./images/memo.png)\n",
72-
"\n",
7371
"## Memoization Python\n",
7472
"\n",
7573
"[1] From Bhargava chapter 8"

0 commit comments

Comments
 (0)