Q. Which method checks if a string starts with a prefix?
Solution:
startswith() checks if a string begins with a specified prefix, e.g., ‘Python’.startswith(‘Py’) is True.
Get Question Bank
Strengthen Your Practice with our comprehensive question bank.