function test(a, b){
    if (arguments.length === add.length) {
        console.log("形参和实参个数相等");
    } else {
        console.log("形参和实参个数不等");
    }
}

test(1); // "形参和实参个数不等"

 

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2021-11-18
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-12-26
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2021-11-16
  • 2021-11-18
  • 2022-12-23
相关资源
相似解决方案