Computer Science
Suggest appropriate functions for the following tasks:
- To check whether the string contains digits
- To find for the occurrence a string within another string
- To convert the first letter of a string to upper case
- to capitalize all the letters of the string
- to check whether all letters of the string are in capital letters
- to remove from right of a string all string-combinations from a given set of letters
- to remove all white spaces from the beginning of a string
Python String Manipulation
39 Likes
Answer
- isdigit()
- find()
- capitalize()
- upper()
- isupper()
- rstrip(characters)
- lstrip()
Answered By
20 Likes
Related Questions
Which functions would you choose to use to remove leading and trailing white spaces from a given string?
Try to find out if for any case, the string functions isalnum( ) and isalpha( ) return the same result
In a string slice, the start and end values can be beyond limits. Why?
Can you specify an out of bound index when accessing a single character from a string? Why?