Python introduction to programming | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

Python introduction to programming

Given a list =[102,343,'que',2.2,50], what would be output of print(list[0:2]) .

22nd Aug 2018, 11:23 AM
Lawrence Hunter
Lawrence Hunter - avatar
4 Answers
+ 4
Lawrence Hunter you could literally test this on sololearn playground
22nd Aug 2018, 1:04 PM
Markus Kaleton
Markus Kaleton - avatar
+ 2
you should complete Python Basic Course. QA should be consulted when you're in trouble not to test others skills by asking question you know answers of.
22nd Aug 2018, 11:51 AM
Aoun Naqvi
Aoun Naqvi - avatar
0
[0:2] returns the first two elements of the list, starting at 0 Output: [102, 343]
22nd Aug 2018, 11:28 AM
Steppenwolf
Steppenwolf - avatar
0
thanks@steppenwolf am new to programing how did u come up with the answers☺
22nd Aug 2018, 11:32 AM
Lawrence Hunter
Lawrence Hunter - avatar