LED not as bright on arduino

hello, i wrote a sketch shown bellow. basically when i press a button, position of servo changes and LED will indicate the position. however, the LED seems really dim. but when i upload a sketch,the LED which i connect to PIN 13, blinks brightly. is there a problem with my sketch that makes the LED not as bright?

#include <Servo.h> 
Servo myservo;
int Red = 13;
int Green = 12;
const int buttonPin = 2;
int buttonState = 0; 

void setup() {
 myservo.attach(7); 
  myservo.write(90);
pinMode(buttonPin, INPUT_PULLUP);   
}

void loop()
{
  buttonState = digitalRead(buttonPin);
  if (buttonState == LOW) {
    myservo.write(175); 
    digitalWrite(Green, HIGH);
    digitalWrite(Red, LOW);
  }
  else
  buttonState = digitalRead(buttonPin);
  if (buttonState == HIGH) {
  myservo.write(90); 
   digitalWrite(Green, LOW);
    digitalWrite(Red, HIGH);
}
}

thanks for the advice

Set the LED pins as outputs!

Mark

Agreed.

void loop()
{
  buttonState = digitalRead(buttonPin);
  if (buttonState == LOW) 
  {
    myservo.write(175); 
    digitalWrite(Green, HIGH);
    digitalWrite(Red, LOW);
  }
  else
    buttonState = digitalRead(buttonPin);
  
  if (buttonState == HIGH) {
    myservo.write(90); 
    digitalWrite(Green, LOW);
    digitalWrite(Red, HIGH);
  }
}

I'm not sure I understand your logic - buttonState is not LOW, then it must be HIGH, so there's no need to read it again, and no need to test it; a simple "else" is all that is required.

void loop()
{
  int buttonState = digitalRead(buttonPin);
  if (buttonState == LOW) 
  {
    myservo.write(175); 
    digitalWrite(Green, HIGH);
    digitalWrite(Red, LOW);
  }
  else
  {
    myservo.write(90); 
    digitalWrite(Green, LOW);
    digitalWrite(Red, HIGH);
  }
}

hi, thanks for the suggestion =) will take it into consideration in the future!