In this article, you will see how to remove quotes from a string in Python. You can use this strip()
method for this task.
Step 1: Create a string
str = "'CodeAllow'" print("str = ", str) print("str type = ", type(str))
Step 2: Remove quotes
print("str = ", str.strip("'")
Output:
str = 'CodeAllow'
str type = <class 'str'>
str = CodeAllow
Free resources to learn advanced skills: AiHints and CodeAllow