Can I reduce this further??

This is not really a question but I am too excited not to talk about it.

I only recently got my Arduino. I used to code about 20 years ago during a computer science degree but have none done any since. I got my Arduino and my interest has been piqued. I wrote some code to have an LED single digit display count from 0 to 9. I did it long hand then did my best to reduce the code using functions and arrays. Even though all the electronics does is count numbers, I’m hooked. Do you think I could reduce the code any more? (The only thing that is left out below is which PIN lights which part of the LED but I don’t think that matters to see if you think I could reduce the code.)

I just need to decide what to do next.

*** The Code ***

int PIN = 0;

int CreateDigit( int LCD1, int LCD2, int LCD3, int LCD4, int LCD5, int LCD6, int LCD7, int LCD8 ) {

int ThePins[8] = {LCD1, LCD2, LCD3, LCD4, LCD5, LCD6, LCD7, LCD8};

for (int x = 0; x < 8; x++){

if (ThePins == 1) {digitalWrite(x+1, HIGH);} else {digitalWrite(x+1, LOW);}
}
}

int One() { CreateDigit(0,1,0,0,0,0,0,1); }
int Two() { CreateDigit(0,0,1,1,1,0,1,1); }
int Three() { CreateDigit(0,1,1,0,1,0,1,1); }
int Four() { CreateDigit(0,1,0,0,1,1,0,1); }
int Five() { CreateDigit(0,1,1,0,1,1,1,0); }
int Six() { CreateDigit(0,1,1,1,1,1,1,0); }
int Seven() { CreateDigit(0,1,0,0,0,0,1,1); }
int Eight() { CreateDigit(0,1,1,1,1,1,1,1); }
int Nine() { CreateDigit(0,1,1,0,1,1,1,1); }
int Zero() { CreateDigit(0,1,1,1,0,1,1,1); }

void setup(){

for (PIN = 1; PIN < 9; PIN++) {pinMode(PIN, OUTPUT);}
}

void loop() {
Zero(); delay(500);
One(); delay(500);
Two(); delay(500);
Three(); delay(500);
Four(); delay(500);
Five(); delay(500);
Six(); delay(500);
Seven(); delay(500);
Eight(); delay(500);
Nine(); delay(500);
}

You could just build an array with the bit patterns and display by indexing to it with the digit you want.

byte bitPatterns[] = { 0b01110111, 0b01000001, 0b001110011 ... etc

void displayNumber(int whatNumber){
     byte thePattern = bitPatterns[whatNumber];

     // here goes a for loop to pull the bits out of thePattern and write the pins 
}

An example