Skip to content

Latest commit

 

History

History
59 lines (54 loc) · 2.05 KB

File metadata and controls

59 lines (54 loc) · 2.05 KB

Welcome to Data Structs

This is a tutorial made by Nicholas Cable, on Nov. 16, 2020. This will help people understand Python Data Structures through a series of readings and practice problems.

  • [Queues]

    1. How is it organized/data stored
      • Stored in a list
      • For problems, store class inside another class (easier to work with)
    2. FIFO
      • First in First out
      • remove from beginning of list instead of end
      • Priorities?
    3. Sample problems
      • Adding/Removing from list
        1. How to add to a queue (insert and not append [tell difference between the two])
        2. How to remove from a queue (dequeue)
      • Class registration
        1. How many spots in class?
        2. Who signed up first? (could just use index to find that)
        3. What happens when someone drops the class?
  • [Linked Lists]

    • Design of linked list (include image)
    • How does it link to each other
      • Each item is a node
      • Next and prev links
    • How does it save memory (uses space in memory instead of array of data)
      • place in memory to store data
      • how to access the data
    • When to use it
    • performance
      • O(n) perfomance
      • Run through list using 'yield' to get each point
    • Possible Sample Problems
      • Problem 1
        1. Creating linked list
        2. Looping through linked list
        3. Getting sum of all values of list
      • Problem 2 1.
  • [Trees]

    • What does a tree look like?
      1. Looks like a literal tree (with branches)
      2. Add a diagram with more details
    • How is data stored
      1. Unbalanced tree (add image here)
      2. Balanced tree (add image here)
      3. Function to balance tree
    • Perfomance of a tree
      1. log(n) performance
      2. Functions to run through tree
      3. Recursion!
    • Possible sample problems
      1. Adding values to a tree. Removing values?
      2. Balancing tree?

These three topics will be covered in this repository.