The shortest solutions to CodingBat problems that I can come up with.
- java and python solutions
- explanations for all uses of regex (regexplanations?) are included
- doc comments for everything
- nearly all of the solutions are one-liners
- some have line breaks for readability though
About imports
Imports in CodingBat are kind of weird, for example java.util.stream.Collectors
is automatically imported
but java.util.stream.IntStream
is not.
I'll use imports in my files for when CodingBat automatically imports it for you, otherwise I'll use FQNs.