Luminate a single LED, casting a soft glow like a lone star in the night.
Use a forever loop to continuously check if the value of the built-in light sensor is below a threshold, and depending on it, turn the RGB LED A on or off.
basic.forever(function () {
    if (input.lightLevel() < 50) {
        sb.setRgbLedColorRGB(sb.rgbLed(SBRgbLed.RgbLedA), 100, 0, 0)
    } else {
        sb.setRgbLedColorRGB(sb.rgbLed(SBRgbLed.RgbLedA), 0, 0, 0)
    }
})If using micro:bit for the first time, follow this setup.