From 6644298010435e4200a00f1c39fd27ca77a6837a Mon Sep 17 00:00:00 2001 From: zhilv Date: Tue, 9 Dec 2025 09:15:57 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E5=AE=8C=E5=96=84=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Web/test8/opreaArr.html | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Web/test8/opreaArr.html b/Web/test8/opreaArr.html index bb99a52..4250624 100644 --- a/Web/test8/opreaArr.html +++ b/Web/test8/opreaArr.html @@ -31,9 +31,10 @@ // 定义一个函数displayOutput,用于将数组元素以字符串形式展示在h1标签中 const displayOutput = (a) => { - return a.join(" "); + output.innerText += "displayOutput(): " + a; } - output.innerHTML += "displayOutput(): " + displayOutput(numbers) + "
"; + displayOutput(numbers); + output.innerHTML += "
"; // 将doubledoutput数组中的元素以字符串的形式显示在h1标签中 output.innerHTML += "doubledoutput: " + doubledOutput + "
";