What are negative indexes and why are they used?
Answers were Sorted based on User's Feedback
Answer / nashiinformaticssolutions
Negative indexes are those that come from the end of the string, tuple, or list.
The last entry in the array is indicated by Arr[-1]. Arr[]
| Is This Answer Correct ? | 0 Yes | 0 No |
Answer / glibwaresoftsolutions
Negative indexes are those that come from the end of the string, tuple, or list.
The last entry in the array is indicated by Arr[-1]. Arr[]
| Is This Answer Correct ? | 0 Yes | 0 No |
Negative indexes are those that come from the end of the string, tuple, or list.
The last entry in the array is indicated by Arr[-1]. Arr[]
| Is This Answer Correct ? | 0 Yes | 0 No |
Answer / Nitin Kumar Verma
A tuple is a collection of immutable ordered elements (similar to lists). Tuples are defined by enclosing the elements in parentheses `()`. Unlike lists, tuples cannot be changed after creation. They can contain any type of data and support indexing, slicing, and other common operations.
| Is This Answer Correct ? | 0 Yes | 0 No |
Explain the difference between append vs extend in list?
What is the pass statement in python?
What is a unit test in Python?
Which python function will you use to convert a number to a string?
When do you use list vs. tuple vs. dictionary vs. set?
What is thread join in python?
Does python support switch or case statement in Python? If not what is the reason for the same?
Convert a string representation of list to list.
Can we use Python in HTML?
Why python is called python?
Is python object-oriented? What is an object-oriented programming
What are key features of python?