【代码】使值递增 发表于 2020-05-24 更新于 2023-05-18 阅读次数: 前言关卡攻略 源代码12345678910111213var gemCounter = 0while !isBlocked || !isBlockedLeft || !isBlockedRight { if isBlocked && isBlockedLeft { turnRight() moveForward() } else { moveForward() } if isOnGem { collectGem() gemCounter += 1 }}