Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
var fizzbuzz = Stream.of("", "", "Fizz").cycle()
.zipWith(Stream.of("", "", "", "", "Buzz").cycle(), String::concat)
.zipWith(Stream.from(1), (s, i) -> s.isEmpty() ? i.toString() : s);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.