Question: Write a program that asks user to input an index first, then asks the user to enter words and constructs a list of characters in
Write a program that asks user to input an index first, then asks the user to enter words and constructs a list of characters in each word under the index. If a word does not have the character under the given index then it will be skipped. The program must work exactly like the following example.
For example:
Input Result
x
xy
xyz
xyzt
xyztw
abcdef
blah
Q
Enter an index:
Enter a word or type Q to quit: x
Enter a word or type Q to quit: xy
Enter a word or type Q to quit: xyz
Enter a word or type Q to quit: xyzt
Enter a word or type Q to quit: xyztw
Enter a word or type Q to quit: abcdef
Enter a word or type Q to quit: blah
Enter a word or type Q to quit: Q
List of characters:
ttdh
frog
cat
dog
Q
Enter an index:
Enter a word or type Q to quit: frog
Enter a word or type Q to quit: cat
Enter a word or type Q to quit: dog
Enter a word or type Q to quit: Q
List of characters:
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
