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?

21 of 35 people (60%) answered Yes
Recently 9 of 10 people (90%) 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.