This example code reads the input from a LilyPad Light Sensor compares it to a set threshold named = 'dark'. If the light reading is below the threshold, an LED will turn on.
For more info on the LilyPad Light Sensor see: https://learn.sparkfun.com/tutorials/lilypad-light-sensor-hookup-guide.