Failed comparism between String input from serial monitor and declared String

The if statement doesn't compare the the string gotten from the serial monitor(String pick) with the respective operand. but the code: Serial.println(pick): prints it out.

Pls i would appreciate your help guys

//Led pins
int redLed= 7;
int greenLed = 4;
int blueLed = 2;

//Serial variables
String pick =  ;
String msg = "What color of led do you want on: ";
String errMsg = "The color you entered is not available";


void setup() {
  // put your setup code here, to run once:

  pinMode(redLed,OUTPUT);
  pinMode(greenLed,OUTPUT);
  pinMode(blueLed,OUTPUT);

 Serial.begin(9600);

}

void loop() {
  // put your main code here, to run repeatedly:
  Serial.print(msg);

   while(Serial.available() == 0){
    
   }

   pick = Serial.readString();
   Serial.println(pick);

  

   if ( pick == "red" || pick == "Red" || pick. == "RED"[color=red][/color]){
     digitalWrite(redLed,HIGH);
     digitalWrite(greenLed,LOW);
     digitalWrite(blueLed,LOW);
  
   }  else if(pick=="green"||pick=="Green"||pick=="GREEN"){
     digitalWrite(redLed,LOW);
     digitalWrite(greenLed,HIGH);
     digitalWrite(blueLed,LOW);
  
   }  else if(pick=="blue"||pick=="Blue"||pick=="BLUE" ){
     digitalWrite(redLed,LOW);
     digitalWrite(greenLed,LOW);
     digitalWrite(blueLed,HIGH);
   } else{
      Serial.println(errMsg);
      digitalWrite(redLed,LOW);
      digitalWrite(greenLed,LOW);
      digitalWrite(blueLed,LOW);
      
    }
}

pick. == "RED" what’s the “.” ?

The if statement doesn’t compare the the string gotten from the serial monitor

Yes it does.

What is the serial monitor line ending?

It should be “none”