rstrip() method in Python String Module
rstrip methodin string module returns the output by removing any spaces available in the right side of the string.
Syntax:
Str.rstrip()Example-1:
text = " capital "
x = text.rstrip()
print("Hyderabad is", x, "of Telangana")
Output :
