js return

<!doctype html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>return</title>
</head>

<body>
    <script>

       function f() {
           return;
       }

       console.log(f()==undefined);  // true.
    </script>
</body>

</html>

猜你喜欢

转载自blog.csdn.net/weixin_42193179/article/details/85326431