Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

python index

TestString = "Python Is Fun"

print(TestString[2])
#This will print "t"

#printing it backwards would be
print(TestString[::-1])

#these an be stored in variables too.
a = TestString[0:5]
print(a)
Source by docs.python.org #
 
PREVIOUS NEXT
Tagged: #python #index
ADD COMMENT
Topic
Name
1+6 =