# Import necessary modules
# 導入必要的模組
from machine import Pin
import time

# Initialize a Pin object to interact with GPIO 21, and set it as an output pin
# 初始化一個 Pin 物件來操作 GPIO 21,並將它設為輸出腳位
led = Pin(21, Pin.OUT)

# Loop 10 times
# 迴圈執行 10 次
for _ in range(10):
    # Toggle the LED value (if it's 0, change it to 1; if it's 1, change it to 0)
    # 切換 LED 的電位(如果是 0,改為 1;如果是 1,改為 0)
    led.value(not led.value())
    
    # Pause the execution of the program for 1 second
    # 暫停程式的執行 1 秒
    time.sleep(1)