3 ms·
"The first character in the instructions has position 1, the second character has position 2" This project seems awesome but playful -1 for non-zero-based-inde
by famousactress 11y ago
"The first character in the instructions has position 1, the second character has position 2"
This project seems awesome but playful -1 for non-zero-based-indexing :)
[Edit:]
another note (obviously I'm hooked).. This instruction isn't 100% parseable. It's not clear whether the desire is for three unique vowels need to appear or if three positions in the string need to be vowels. For instance, would 'aaa' qualify?
"It contains at least three vowels (aeiou only), like aei, xazegov, or aeiouaeiouaeiou"
[Edit Again: Nevermind... the test example 'aaa' clears it up]
- SanderMak 11y agoIt played pretty nicely with using map followed by a scanLeft (which prepends its starting element) on the input. Happy accident...