Please use the predefined constants; it makes it a lot easier to understand. Change
void setup()
{
pinMode(ledA, 1);
pinMode(ledB, 1);
pinMode(ledC, 1);
pinMode(sequenceup, 0);
pinMode(sequencedown, 0);
}
to
void setup()
{
pinMode(ledA, OUTPUT);
pinMode(ledB, OUTPUT);
pinMode(ledC, OUTPUT);
pinMode(sequenceup, INPUT);
pinMode(sequencedown, INPUT);
}
Next you mention pull-up resistors in your comments. Do you use external pull-ups? If not, you need to change the last two statements to
pinMode(sequenceup, INPUT_PULLUP);
pinMode(sequencedown, INPUT_PULLUP);
Also, please use the predefined constants for the digitalWrite in your code; 1 would be HIGH and 0 would be LOW. e.g.
if (sequence == 3)
{
digitalWrite(ledA, LOW);
digitalWrite(ledB, LOW);
digitalWrite(ledC, HIGH);
}
Next your code always will execute sequence 1, regardless if a button is pressed or not. Your code also repeats the selected sequence. Are both the intention?
delay(250);//delay to prevent going through sequence too quick from holding the button or pressing too long. But I would prefer this to not happen, even if I hold the button continuously.
Based on the last part of the comment, you need to have a look at the state-change-detection example that comes with the IDE. You want to react on the falling edge (when the button becomes pressed, the signal goes from HIGH to LOW) and do nothing till a rising edge is detected (button is released, signal goes from LOW to HIGH).
The code as you can see lights each led from 8 - 10 but stays high through each up and down cycle.
Because you never write it low again 