hey = 'abheysded'
print(hey[2])
it prints the letter ‘h’ a b h e y s d e d
0 1 2 3 4 5 6 7 8.
fruit = 'apple'
letter = fruit[2]
print(letter)
a p p l e
0 1 2 3 4, it prints the letter ‘p’
$ C:/python/Python311/python.exe c:/Users/LENOVO/OneDrive/Desktop/python/hello.py p
fruit = 'apple'
x = 4
w = fruit[x - 1]
print(w)