Medium
Count Without a List
Read words and a letter. Print how many words start with the letter (any case) using
sum(1 for …) over a generator expression, then the first such word using next(…, 'none').Input
Two lines.
Output
Two lines.
Sample 1
Input
Apple banana avocado cherry a
Output
2 Apple
Sample 2
Input
x y z q
Output
0 none
Output appears here