LED turning on from a light sensor

So when you posted that you were given a warning that it was not posted correctly, but you ignored that and clicked on "Post anyway". Is this correct?

Please post it correctly so I can try to compile it myself and see what mistakes you have made.
Learn how to post code here and in general how to ask and respond to questions here
how to get the best out of this forum