Search
 
SCRIPT & CODE EXAMPLE
 

PYTHON

how to get a specific character in a string on number python

# An example text
text = "This is text"
# print the [0] first character of the sample text, 
#			[4] fifth character,
#			[0: 4] first to fifth character,
#			[-1] last character.
print(tekst[0], tekst[4], tekst[0:4], tekst[-1])
Comment

PREVIOUS NEXT
Code Example
Python :: python mongodump 
Python :: blender change text during animation 
Python :: dataframe, groupby, select one 
Python :: python run linux command and get output 
Python :: python gui framework 
Python :: python typing 
Python :: How To Display An Image On A Tkinter Button 
Python :: how to print text in python 
Python :: python string lenght 
Python :: python format string with list 
Python :: how to find duplicate strings in a list of string python function 
Python :: how to add axis labels to a plotly barchart 
Python :: python tkinter programming project ideas 
Python :: python if in list 
Python :: assign exec function to variable python 
Python :: deleting key from dictionary 
Python :: Python NumPy tile Function Example 
Python :: python remove all occurrence of an items from list 
Python :: how to close opened file in python 
Python :: hexdigest python 
Python :: why is c++ faster than python 
Python :: python count the vowels 
Python :: sorted multiple keys python 
Python :: round python print 
Python :: precision accuracy recall python example 
Python :: python modulo 
Python :: python built in libraries 
Python :: append element to list py 
Python :: python create empty list size n 
Python :: numpy datatime to string 
ADD CONTENT
Topic
Content
Source link
Name
9+8 =