11 - how do I get a sublist in python? (Python tutorial for beginners 2019)

preview_player
Показать описание


Enroll for exercises, tutorials, courses, and projects...

Enroll in Learn Python™ course

==================================================
Connect With Me!

Snapchat ► Rafeh1
Рекомендации по теме
Комментарии
Автор

Easy thought. Instead of doing try the following:

len_adj = window_size - 1

for i in range(len(digits)-len_adj):
print(digits[i : i+window_size])

MR-sqiu
Автор

Very sleek of Python to use "negative-ith" location of a list. Thank-you for this vlog, Aaron!!

TravisGarnett
Автор

We could also use an if to check the length of the slice, to not hard code any value, and let the range to go to the end (but the trade off will be some additional operations).
And the math was actually "len(digits)-window_size+1"
And by the way, great videos! :)

mihaisabadac
Автор

Thanks very much for the video. Learn ed a lot

carlosdasilva
Автор

how to access thislist=[ [ "abc" ], [def], ["ghi"] ] how to access individual lists which is inside a list

OrvixStudios
Автор

Hey hey! Huge fan of your channel! Hey #Quazi, would you demo us different Python tools? I know you talked a lot about Flask and Django. But Python has much to it! You can automate CI/CD, do automated UI testing, load and performance testing.

Eugene.Berezin
Автор

Thanks #Qazi for conducting freelancer 🙏

venkateswarlutummala
join shbcf.ru