#K95357. Wildcard Word Generator
Wildcard Word Generator
Wildcard Word Generator
Your task is to generate words by replacing the wildcard character '*' in a given string with all lowercase letters from 'a' to 'z'. For each test case, the input string will contain exactly one '*' character. The generated words must be distinct and sorted in lexicographical order.
Note that the total number of words generated for any input will always be \(26\), since there are 26 lowercase letters.
inputFormat
The input is read from standard input (stdin) and has the following format:
- The first line contains an integer \(T\) representing the number of test cases.
- Each of the next \(T\) lines contains a single string that includes exactly one '*' character.
outputFormat
For each test case, output a single line to standard output (stdout) containing 26 words. Each word is formed by replacing the '*' character with a lowercase letter from 'a' to 'z'. The words must be printed in lexicographical order and separated by a single space.
## sample1
a*c
aac abc acc adc aec afc agc ahc aic ajc akc alc amc anc aoc apc aqc arc asc atc auc avc awc axc ayc azc
</p>