from machine import Pin
from time import sleep

L = [Pin(0, Pin.OUT), Pin(1, Pin.OUT), Pin(2, Pin.OUT), Pin(3, Pin.OUT)]

while 1:
    for i in range(4):
        L[i].on()
        sleep(1)

    for i in range(3,-1,-1):
        L[i].off()
        sleep(1)
BOOTSELLED1239USBRaspberryPiPico©2020RP2-8020/21P64M15.00TTT