Python Forum

Full Version: Letters used
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Usually don't have an issue with tasks like this but I can't think of a simple way to do this task:
----------------------------------------------------------------------------------------------------------------------------------------
Design a program that will ask the user to enter a sentence.
Using a list, use the input sentence to record which letters have occurred in the sentence.
So, the program output would be able to state “The sentence used 19 letters of the alphabet” The letters used were “a,c,f,g, etc…
You should also get the program to count the occurrences of each letter.
----------------------------------------------------------------------------------------------------------------------------------------
I'm probably being really dumb but any help would be appreciated.
What have you tried? (Please make sure to use code tags when you post your code.)