/Yui

Collection of data structures and algorithms

Primary LanguageC++

Yui

Collection of data structures, algorithms and other puzzles:

  • BST with predecessor and successor access in constant time

  • RB tree (rebalancing is done through a constant number of node rotations, contrary to AVL trees)

  • Heap and heap sort. Merge sort

  • Radix tree implementation with insertion, deletion, search and auto-completion functionality based on the Damerau-Levenshtein distance

  • Segment tree for logarithmic minimum retrieval in 1D range

  • Regular segment tree for stabbing queries in logarithmic time

  • Minimum Range Query in constant time after a preprocessing step in linear time

  • Knuth–Morris–Pratt string searching algorithm

  • Quick select (finds the kth minimum element in average linear time)

  • Lowest Common Ancestor in constant time after a preprocessing step in linear time

  • Egg-breaking problem, Hanoi tower, Skyline problem, WordLadder, maximum contiguous sum/product, closest contiguous sum to target...