Question: Write a python program that inputs individual letters and creates a string of these letters except it will exclude the letter x. To signal the

Write a python program that inputs individual letters and creates a string of these letters except it will exclude the letter x. To signal the end of the input, the user will input the letter z. The final string should not include any x and should not include the z. The program must print the final string.

Sample input and output

Enter a character: o

Enter a character: x

Enter a character: k

Enter a character: a

Enter a character: x

Enter a character: y

Enter a character: z

The final string is okay

Cannot use break in the answer as we have not covered that in class yet.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!