Here’s the heart of the calculator in C# – a variable number of fractions get’s passed as input, and the lowest common denominator is calculated as output. The first thing that happens is the highest denominator of the input fractions is determined using a LINQ statement, following that – a potentially recursive function call does the rest: