|
@@ -0,0 +1,19 @@
|
|
|
+/*
|
|
|
+ * @Description: 一行if双返回值
|
|
|
+ * @Autor: kindring
|
|
|
+ * @Date: 2021-10-29 10:28:57
|
|
|
+ * @LastEditors: kindring
|
|
|
+ * @LastEditTime: 2021-10-29 10:30:48
|
|
|
+ * @LastDescript:
|
|
|
+ */
|
|
|
+
|
|
|
+/**
|
|
|
+ *
|
|
|
+ */
|
|
|
+function oneIfTwo(n) {
|
|
|
+ if (n == 1) return (console.log(n)) & (console.log('被阻止了')) & (console.log('------------'))
|
|
|
+ console.log('正常运行');
|
|
|
+}
|
|
|
+
|
|
|
+oneIfTwo(1);
|
|
|
+oneIfTwo(2);
|