How to Flip Equivalent Binary Trees? May 2, 2019 algorithms, c / c++ No Comments For a binary tree T, we can define a flip operation as follows: choose any node, and swap the left and right child subtrees. A binary tree X is … [Continue Reading...]
How do you Design a Circular FIFO Buffer (Queue) in C? July 18, 2018 c / c++, data structure 8 Comments I was recently being asked by this question: How do you Design a Circular FIFO (First-In First-out) Buffer (Queue) in C? You need to implement two methods: fifoRead and … [Continue Reading...]