Ad
  • Default User Avatar

    If the test does not check the type of chained to be a function, you could just get rid of it and rename your class to chained

  • Custom User Avatar

    Your code us clear. But I think the program description is the result larger than 140. The input is not. Since the input contains many spaces , the input is always larger than the result. So , although input is larger than 140 , the result may not larger than 140. So , your code does not work welll if the input is larger than 140 while the result is not.