cat” as (3 ∙ 262) + (1 ∙ 261) + (20 ∙ 260) = 2074
A helpful example for me
cat” as (3 ∙ 262) + (1 ∙ 261) + (20 ∙ 260) = 2074
A helpful example for me
In general, the runtime of a separate chaining hash table is determined by a number of factors. We’ll often need to ask a couple of questions about the hash function and the hash table before we can properly analyze or predict the data structure performance.
I feel like seeing game items is a great way to visualize hash tables
But we could also state it more simply as just T(N) = 2T(N / 2) + N because the runtime is the same regardless of which half we’re discussing.
Why will it be the same regardless of which one we are discussing?
T(N / 2) + 1
This is recursive time because you would check two paths and keep going from there and keep splitting till your code finishes
How do we model the number of steps it takes to run an algorithm in general? Here are two factors that can affect the number of steps to compute indexOf.
Is this talking about visually or more equations wise?
n each iteration, selection sort selects the smallest unsorted element and swaps it into its sorted place
This video really helps with visualizing the sort method selection we talked about