const rawTitle = " js 核心练习 "; const tags = ["变量", "条件", "函数"]; const cleanTitle = rawTitle.trim(); const upperTitle = cleanTitle.toUpperCase(); const hasJS = upperTitle.includes("JS"); const tagLine = tags.join("、"); console.log("清洗后标题:", cleanTitle); console.log("大写标题:", upperTitle); console.log("是否包含 JS:", hasJS); console.log("标签列表:", tagLine);