One by one

Report a typo

You will get a word as input. Define a generator that would generate letters from a given word one by one, using the yield from expression for this. Print out the letters on separate lines.

There are several ways to solve such tasks, but this time use yield from, please.

Sample Input 1:

hello

Sample Output 1:

h
e
l
l
o
Write a program in Python 3





___

Create a free account to access the full topic