Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Please help me add a python string to this python code to ask for vowels within the string or input. string _ input = input
Please help me add a python string to this python code to ask for vowels within the string or input.
stringinput inputEnter string:
# Code responsible for counting characters
lettertocount input Enter a character to count in the string:
charactercount stringinput.count lettertocount
# Code responsible for case conversion
words stringinput.split # String is split into words
uppercaseletter wordcapitalize for word in words # Each first letter of each word is capitalized
titlecasestring joinuppercaseletter # Works are brought back together as a string
Code responsible for checking if specific initials are present
initials inputEnter your initials: upper
initials present initials in stringinput.upper
# Code responsible for displaying results
print fCharacter lettertocount count in the string: character count
print fString in title case: titlecasestring
print fAre your initials initials present in the string? Yes if initials present else No
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started