added tests

This commit is contained in:
Brian Bjarke Jensen
2025-09-19 19:38:10 +02:00
parent 0abd398c10
commit b426d43de0
16 changed files with 1919 additions and 0 deletions
+15
View File
@@ -0,0 +1,15 @@
console.log("Hello, World!");
const calculator = {
add: (a, b) => a + b,
subtract: (a, b) => a - b,
multiply: (a, b) => a * b,
divide: (a, b) => {
if (b === 0) {
throw new Error("Cannot divide by zero");
}
return a / b;
},
};
module.exports = calculator;