Skip to content

Instantly share code, notes, and snippets.

@Ajith-develpoer
Created October 21, 2020 02:59
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Ajith-develpoer/691770f125348dd60954849ef3f1103d to your computer and use it in GitHub Desktop.
Save Ajith-develpoer/691770f125348dd60954849ef3f1103d to your computer and use it in GitHub Desktop.
tables in medium
We can make this file beautiful and searchable if this error is corrected: It looks like row 15 should actually have 3 columns, instead of 2. in line 14.
Operation,Averge Case, Worst Case
Copy,O(n),O(n)
Append[1],O(1),O(1)
Insert,O(n),O(n)
Get item,O(1),O(1)
Set item,O(1),O(1)
Delete item,O(n),O(n)
Iteration,O(n),O(n)
Get slice,O(k),O(k)
Del slice,O(n),O(n)
Set slice,O(k+n),O(k+n)
Extend[1],O(k),O(k)
Sort,O(n log n),O(n log n)
Multiply,O(nk),O(nk)
X in s,O(n)
min(s),max(s),O(n)
Get length,O(1),O(1)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment