• Leo Uino@lemmy.sdf.org
    link
    fedilink
    arrow-up
    71
    ·
    1 year ago

    TDD

    const max12 = (x, y) => {
        if (x === 1 && y === 2) {
            return 2;
        } else if (x === 7 && y === 4) {
            return 7;
        } else {
            return x;
        }
    };