Slice in String of Python

Slice: A slice is used to pick out a part of String. This is a easy way to pick out a needed number of string from a file or a documents. Slice makes easy to search of String in rapid form. Here we see a small example of Slice .. String s= "abcdefghij". The index and terms of following String is below : fig: Index and term of String Now the method of Slicing String is Given Below in Figure: As in figure you Slice any String by given it's particular index. The basic structure of Slice is : String_name [starting location : Ending location+1]