Skip to content

roiei/algo

Repository files navigation

algo

Hi, I'm Roy. I updated some instructive codes here because I just want to share my codes written throughout studying various kins of algorithms and data structures.

A. data structure

  1. bst.py : binary search tree
  2. graph.py : undirected, directed, weighted graph, DFS, BFS, MCST PFS, MCST Krukusal, PFS, Dijkstra
  3. hash_linear_probing.py : hash implementation with linear probing as collision avoidance
  4. hash_separate_chanining.py : hash implementation with separate chaining as collision avoidance
  5. prio.queue.py : priority queue implementation based on heap sort
  6. Set.py : set data structure

B. algorithms

  1. MazeGraph.py : algorithm to check if it is possible to get through to the exit point with the given array

  2. quick_sort.py : quick sort implementation recursive version, stack version

  3. sort.py : basic sort algorithms with O(N^2)

    select sort : i is from 0 to n-1, j is from i to n-1, and compare i to j -> exchange

    insert sort : i is from 1 to n-1, j is from i to 0, compare j-1 to j -> exchange

    boubble sort : i is from 0 to n-1, j is from 1 to n-i, compare j-1 to j -> exchange

  4. merge_sort.py : merge sort using merge is added merge sort is merging two parts of source from the unit size 1 and the unit size is going to increased as multiple of 2

C. Problem Solving

  1. Algorithm code for the problems from 'LeetCode'

  2. Algorithm code for the problems from HackerRank, acmpic, etc.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published