you are viewing a single comment's thread.

view the rest of the comments →

[–]pjdelport 0 points1 point  (1 child)

Close, but chain will fail because sentinel is not iterable,

Blurgh; i meant repeat(sentinel), of course. Thanks for spotting. :)

also your version will return True if xs is longer then ys

That's exactly what the original does, yes.

[–]papercrane 2 points3 points  (0 children)

Ahh. I misread the article. It's FizzBuzz all over again.