faqts : Computers : Programming : Languages : Python : Snippets : Strings

+ Search
Add Entry AlertManage Folder Edit Entry Add page to http://del.icio.us/
Did You Find This Entry Useful?

18 of 31 people (58%) answered Yes
Recently 7 of 10 people (70%) answered Yes

Entry

How do I extract a part of a string, e.g. all letters from second to fifth?

Nov 28th, 2005 07:11
Tom Clancy, Zadig Babylonian,


s[2:5] should give you that.