Starter project for kata (Node, TypeScript, Jest)
git clone https://github.com/mathieueveillard/js-kata-starter.git
cd js-kata-starter
npm install
npm test
Write a program that implements the addition of fractions. Fractions must be reduced. An implementation of the greatest common divisor (GCD) is provided:
function gcd(a, b) {
return b === 0 ? a : gcd(b, a % b);
}