What will be the output of the following Python statement? x="abcd" print(x[2:])
Answers
Answered by
3
Answer:
the output will be of this phython statement is
'c'
Answered by
0
Output of the statement will be cd.
Explanation:
- in python programing language a command of type means data stored at the index to end or last index of the x.
- for example , A=[l, m, n, o, p, q] then A[:]= [m, n, o, p, q]
- here, is stored as ,
- hence, the statement print(x[]) will print the values starting at index till the value at last index (that is )
- Therefore, final output is
Similar questions