I am quite new at Arduino circuits. I understand circuits, but I am totally new at programming. I received an Arduino Uno Rev3 starter kit for Christmas and immediately began assembling the circuits and using the pre-made example codes to make them function. I got the hang of that, and decided to start building some circuits of my own and programming. I wanted to give else...if programs a try so I made a simple circuit that (hypothetically) uses a photoresistor input to control an LED. This is the code I constructed:
My IDE is telling me that i have an "else without a previous if", but it seems to me as if my previous if is present. Not sure what to do. Help is much appreciated!
Well... That got the code to verify and upload, but the light seems to be irresponsive. It is on, regardless of the light level picked up by the photoresistor.