helper.js:
export const min = (a, b, c) => {
if (a<b && b<c) {
return a;
} else if (a>b && b<c) {
return b;
} else if (a>c && b>c) {
return c;
}
}
solution.js:
import { min } from './helper.js';
const a = 10;
const b = 5;
const c = 3;
console.log(The minimum is ${min(a, b, c)}
);