Category: algorithms
The puzzle is to generate the first few numRows rows of Pascal’s Triangle. Do you need to keep each row in separate variables (row vector)? Apparently no. The trick …
I have asked a question on stackoverflow: inline int test(int n, int tag, int flag) { if (0 == flag) return ((n & tag) == tag); return ((n & …
This puzzle is from Leetcode Online Judge and this may appear quite often during interviews. This puzzle asks you to find the minimal sum for a number triangle. You …
September 20, 2014
32 bit, algorithms, animation, c / c++, code, code library, implementation, linux, programming languages, windows, windows command shell
The following is a up-to-date summary of posts with source codes and binaries. Coding examples help us learn better and quicker. The programming examples are as ‘it is’. I …
We all know that the total number of solution to pick combination of n items out of m items is C(m, n), and sometimes denoted as or . We …