Given a string, find the first word starting with each letter (case insensitive).
Ferulas flourish in gorgeous gardens. as input:
"Ferulas flourish in gorgeous gardens." ^^^^^^^ ^^ ^^^^^^^^ | | | | | --> is the first word starting with `g` | --> is the first word starting with `i` --> is the first word starting with `f`
Then, the output for this sample should be the matched words joined by one single space:
"Ferulas in gorgeous"
Both input and output must be a string representation, or the closest alternative in your language.
Program or function allowed.
You can consider a word being at least one of:
lowercase or uppercase letters, digits, underscore.
This is code-golf, shortest answer in bytes wins.
input: "Take all first words for each letter... this is a test" output: "Take all first words each letter is"
input: "Look ^_^ .... There are 3 little dogs :)" output: "Look _ There are 3 dogs"
input: "...maybe some day 1 plus 2 plus 20 could result in 3" output: "maybe some day 1 plus 2 could result in 3"