Home
Recent Q&A
Java
Cloud
JavaScript
Python
SQL
PHP
HTML
C++
Data Science
DBMS
Devops
Hadoop
Machine Learning
Azure
Blockchain
Devops
Ask a Question
While using slicing in lists, list[0:2] is equivalent to ______.
Home
Python
While using slicing in lists, list[0:2] is equivalent to ______.
0
votes
asked
May 15, 2019
in
Python
by
Derya
edited
Jul 10, 2021
by
sharadyadav1986
While using slicing in lists, list[0 2] is equivalent to ______.
Select the best answerr from below options :
(1)list[:-2]
(2)list[0:3] -1
(3)list[-2:0]
(4)list[:2]
#python
Python-questions-answers
Please
log in
or
register
to answer this question.
0
Answers
Related questions
0
votes
Q: What is the output of the following code? count = 0 while count < 2: print (count, " is less than 2") count = count + 2 else: print (count, " is not less than 2")
asked
May 17, 2019
in
Python
by
Derya
#python
Python-questions-answers
0
votes
Q: What is the output of print tuple[0] if tuple = ( 'abcd', 786 , 2.23, 'john', 70.2 )?
asked
May 16, 2020
in
Python
by
AdilsonLima
#python
Python-questions-answers
0
votes
Q: What is the output of print list[2:] if list = [ 'abcd', 786 , 2.23, 'john', 70.2 ]?
asked
May 16, 2020
in
Python
by
AdilsonLima
#python
Python-questions-answers
0
votes
Q: Which of the following method is used to check equality of two lists in a test, with unitest?
asked
Jun 30, 2020
in
Python
by
GeorgeBell
#python
Python-questions-answers
0
votes
Q: Which of the following decorator is used to assign user defined setup and tear down functions to a test function, while using nose?
asked
Jul 2, 2020
in
Python
by
GeorgeBell
#python
Python-questions-answers
0
votes
Q: Which of the following statement ensures that all tests present in sample_test_module.py are run while using the command python sample_test_module.py
asked
Jul 2, 2020
in
Python
by
GeorgeBell
#python
Python-questions-answers
0
votes
Q: What is the purpose of using self.id in tests, while working with unittest?
asked
Jun 30, 2020
in
Python
by
GeorgeBell
#python
Python-questions-answers
0
votes
Q: ok_ utility from nose.tools is equivalent to ____________.
asked
Jul 2, 2020
in
Python
by
GeorgeBell
#python
Python-questions-answers
0
votes
Q: Using Pop in list will remove the popped up item.
asked
May 17, 2019
in
Python
by
Derya
#python
Python-questions-answers
0
votes
Q: What is the output of the following code? a = 0 if a: print(""""a's value"""") else: print(""""Sorry nothing will get printed"""")"
asked
May 17, 2019
in
Python
by
Derya
#python
Python-questions-answers
...