Hi, I am making a school project until the 14th, but i am new with programming.A photoresistor controlls the leds. If i place my hand over the photoresistor, led2 goes on.If I cover it, but then remove my hand, led1 goes on.

PLEASE HELP ME!

task:1.read the photoresistor2.wait 0,5 seconds3.read the photoresistor again

a)if the light that reaches the photoresistor is interrupted for a short time, set led1 highb)if the light that reaches the photoresistor is interrupted for a long time, set led2 high

=>that means: a)if i move my hand once over it, set led 1 highb)if i cover it, set led 2 high