tab.click(function () {
$(this).addClass("active");
$(this).siblings().removeClass("active");
});
.active{
background: #ccc;
}
.siblings() 返回被選元素的所有同級元素
const code = Math.floor(Math.random() * 1000000).toString().padStart(6, "0");
// 942377
隨機生成六位數字