void loop()
{ //open the loop
if(digitalRead(3)==HIGH)
{ //open the if
forward();
delay(5000);
} //close the if
if(digitalRead(3)==HIGH)
{ //open the if
reverse();
delay(5000);
} //close the if
//<-- loop NOT closed. Add a }
See it now?