Get your
own Python
server
×
Change Orientation
Change Theme, Dark/Light
Go to Spaces
import re #Search for an upper case "S" character in the beginning of a word, and print its position: txt = "The rain in Spain" x = re.search(r"\bS\w+", txt) print(x.span())
(12, 17)