Ad
  • Custom User Avatar

    Ah, my mistake. I returned the original String for i===0. Thanks!

  • Default User Avatar

    Description says:

    if i === 0 : returns an empty string;

    Test-cases expecting a 0-length string are testing left$( aString, 0 )

  • Custom User Avatar

    I don't really understand what testcase might cause the message Expects a 0-length string - Expected: , instead got: Keep It Simple Stupid

    I read it as: when i is an empty String, $left/$right should return an empty String. If I implement it like such and test it myself (eg. Test.assertEquals( left$('Hello o o o World', ''), '');), my test passes but the aforementioned test still fails.

    Could you explain which case this is supposed to test?