• hades@lemm.ee
    link
    fedilink
    arrow-up
    0
    ·
    6 days ago

    I agree, compiled languages prevent large classes of errors, including invoking functions with wrong parameters. However, whether or not you define calling max() with no arguments to be an error or not is unrelated to your language being compiled or interpreted. You could define max() to be -inf in C++ if you wanted, even though the language allows you to prevent invocations of max() with no arguments altogether.