Where do you actually read the button switch? Don't you need to set the led pin to output?
All of those digitalWrites and delays can be replaced by a for loop.
Where do you actually read the button switch? Don't you need to set the led pin to output?
All of those digitalWrites and delays can be replaced by a for loop.