subject

Write a Python function LetterGame() that repeatedly asks the user to input a letter. The function is to count the number of vowels the user entered. The function should stop if the user enters a digit (0-9). a) Use a while-loop and in the while loop ask the user to input a letter or to input a digit to stop. b) Check if the user entered a vowel (if command is your friend) c) If the user entered a vowel increase the counter by one d) If the user entered a digit, output the number of letters the user entered and the number and percentage of vowels among them. e) Call the function. Expected output: You entered 10 letters, 2 of which were vowels. The percentage of vowels was 20%.

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 17:20
[a] create a class called “cycle” which has two instance integer variables as properties, “numberofwheels” and “weight.” create a constructor with two parameters, using the same variable names in the parameter list. assign each variable to numberofwheels” and “weight” respectively. write a separate application to test the class and display its properties. note: do not change the names of the instance variables or the variables listed in the constructor’s parameter list. [b] edit your class cycle by adding a default constructor which will assign the default values of 100 to represent the numberofwheels, and 1000 to represent the weight, by invoking a call to the other constructor. modify your application created in [a] to test the class.
Answers: 3
question
Computers and Technology, 23.06.2019 13:30
Best laptops for college [$100-$500 range]?
Answers: 2
question
Computers and Technology, 24.06.2019 01:30
How would you cite different books by the same author on the works cited page? moore, jack h. folk songs and ballads. salem: poetry press, 1999. print. moore, jack h. ballads in poetry – a critical review. dallas: garden books, 1962. print. moore, jack h. folk songs and ballads. salem: poetry press, 1999. print. –––. ballads in poetry – a critical review. dallas: garden books, 1962. print. moore, jack h. ballads in poetry – a critical review. dallas: garden books, 1962. print. moore, jack h. folk songs and ballads. salem: poetry press, 1999. print. moore, jack h. ballads in poetry – a critical review. dallas: garden books, 1962. print. –––. folk songs and ballads. salem: poetry press, 1999. print.
Answers: 2
question
Computers and Technology, 24.06.2019 10:40
Joe needs to see the slide transitions and animations he has applied to his slides in a large view. which presentation view should he use? in which tab would joe find the animations option to make further changes, if any?
Answers: 1
You know the right answer?
Write a Python function LetterGame() that repeatedly asks the user to input a letter. The function i...
Questions
question
Chemistry, 03.02.2020 00:53
question
Business, 03.02.2020 00:53
Questions on the website: 13722363