Python for Engineers
Solve Problems by Coding Solutions - A Complete solution for python programming
Blog Pages
Blog
News
Distributions
NumPy Tutorials
Self Learning
IDE
Packages
About
String operations to remove white spaces
s=" t ioi ii "
t1=s.rstrip() # removes trailing white space
t2=s.lstrip() # removes leading white space
t3=s.strip() # removes leading and trailing white space
print s
print t1
print t2
print t3
No comments:
Post a Comment
Newer Post
Older Post
Home
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment