Tag: algorithms
Given an array of numbers nums, in which exactly two elements appear only once and all the other elements appear exactly twice. Find the two elements that appear only …
The Matrix Chain Multiplication Problem is the classic example for Dynamic Programming. If there are three matrices: A, B and C. The total number of multiplication for (A*B)*C and …
Given an integer, write a function to determine if it is a power of two. This is not new, and the solution has been posted at Using a Faster …
Bash Shell is powerful. We can accomplish many complex jobs based on the abundant commands. This tutorial presents a Bash shell to check a given number to see it …
May 7, 2014
algorithms, code, code library, data structure, implementation, programming languages, sorting, VBA, vbscript, windows, windows scripting host
Among the simple sorting algorithms, the insertion sorting algorithm is my favourite. Insertion sort is simple to implement and gives an average quadratic O(n2) running time, like other simple …