Ad
  • Custom User Avatar

    Your code fails for blue or BlUe because you are checking the length first before the code logic flow enters the else statement, and obviously multiplying a string (l) with an integer is invalid.

  • Custom User Avatar

    Try adding the following line to the beginning of the function. Then you can determine what input is causing the error.

    print(color)