You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Bug in this test console.log('aabbcc', strComp('aabbcc'), 'aabbcc')
As the book says, if the length of the result is not less than the original should print the original, and it is printing: a2b2c2
Activity
[-]1.6 length bug[/-][+]1.6 Length bug[/+]dawsbot commentedon May 21, 2017
Do you want to fix this @tankwan? I can if not.
heytonytan commentedon May 22, 2017
profnandaa commentedon Oct 2, 2018
@thetonytan - ping!
yuriaps commentedon Sep 27, 2020
Bug in this test
console.log('aabbcc', strComp('aabbcc'), 'aabbcc')As the book says, if the length of the result is not less than the original should print the original, and it is printing:
a2b2c2yuriaps commentedon Sep 27, 2020
I don't see why use the Math.max()...
I would go this way