Ok so i'm just starting out with the arduino. I have a problem with an error popping up in the verify part.
Other parts of the code seem fine til it gets to my loop this is just a simple push button blink sketch.
const int red = 11;
const int switchPin = 2;
void setup() {
pinMode (red,OUTPUT);
pinMode (switchPin,INPUT);
}
void loop() {
for (digitalRead (switchPin) == HIGH) //here it give an error expected ';' before ')' token
{
digitalWrite(red,HIGH);
}
else
{
digitalWrite(red,LOW);
}
}