The factorial of a number, written as n! is defined as n! = n(n − 1)(n − 2)...(2)(1) A generalization of this is the multifactorials where:
Continue ReadingWhy Is Char[] Preferred Over String for Passwords?
In Swing, the password field has a getPassword() (returns char[]) method instead of the usual getText() (returns String) method. Similarly, I have com
Continue ReadingBest Quant Data Sources
Best Quant Data Sources Economic Data World OECD.StatExtracts includes data and metadata for OECD countries and selected non-member economies.
Continue ReadingC++: GUI Component Interaction
Almost every application needs to communicate with the user in some way. Therefore, a substantial part of the code deals with the interaction of progr
Continue ReadingImprove INSERT-per-second performance of SQLite?
Optimizing SQLite is tricky. Bulk-insert performance of a C application can vary from 85 inserts-per-second to over 96 000 inserts-per-second! Back
Continue ReadingC++: Root Mean Square
Compute the Root mean square of the numbers 1..10. The root mean square is also known by its initial RMS (or rms), and as the quadratic mean. Th
Continue ReadingC++: Balanced Ternary
Balanced ternary is a way of representing numbers. Unlike the prevailing binary representation, a balanced ternary integer is in base 3, and each digi
Continue ReadingC++: Forward Difference
Provide code that produces a list of numbers which is the n-th order forward difference, given a non-negative integer (specifying the order) and a lis
Continue ReadingC++: Hofstadter-Conway $10,000 Sequence
The definition of the sequence is colloquially described as: Starting with the list [1,1], Take the last number in the list so far: 1, I'll ca
Continue ReadingC++: Matrix Exponentiation Operator
Most programming languages have a built-in implementation of exponentiation for integers and reals only. Demonstrate how to implement matrix expone
Continue Reading




