Тёмный

Python Lists: Indexing & Slicing 

Real Python
Подписаться 190 тыс.
Просмотров 75 тыс.
50% 1

In this lesson, you’ll see how to access individual elements and sequences of objects within your lists. Lists elements can be accessed using a numerical index in square brackets. This is the same technique that is used to access individual characters in a string.
Click here to learn more: realpython.com/courses/lists-...

Опубликовано:

 

14 июл 2024

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 41   
@JoshyHJoshy
@JoshyHJoshy 3 года назад
This was really informative; brief and to the point. Thank you
@SMajid--SMajid
@SMajid--SMajid 4 года назад
Thanks for using a list of strings, it all became very clear with that!
@jfsosa80
@jfsosa80 2 года назад
Excelent way of putting things simple! thanks for the effort, instant subscriber here. Keep up the good work!
@BinySD1
@BinySD1 2 года назад
Thank you very much! I used it for my self and the things concerning this topic become clear for me after following this video.
@stevenavalos4395
@stevenavalos4395 3 года назад
This video is super helpful ! Thank you I am 16 learning to code and it’s been really difficult
@royersegura5991
@royersegura5991 2 года назад
Thanks so much now I fully grasped how the middle number works.
@noSleep475
@noSleep475 3 года назад
Thank you so much.
@vasavapr
@vasavapr 3 года назад
Thank you!
@pythonlucas
@pythonlucas 3 года назад
Thank you for this video about lists, it helped me out to solve the problem I was stuck with, which result I uploaded on my own channel. I like your content, your explanation is very clear. I hope my own script can be as clean, if someone could give me some feedback, I would really appreciate it. Thank you!
@pauldenver4319
@pauldenver4319 3 года назад
Pro tip : watch movies at flixzone. Been using them for watching a lot of movies recently.
@ryanwinston5066
@ryanwinston5066 3 года назад
@Paul Denver Definitely, been using Flixzone for years myself :)
@shalinisrivastava7250
@shalinisrivastava7250 2 года назад
Thank you so much sir, I was having so much difficulty in this portion,and I was unable to identify it .
@mihirkumar2887
@mihirkumar2887 2 года назад
lots of love awesome teacher
@bhangra20001
@bhangra20001 4 года назад
Excellent video, I have a question. I have the following statement but after the colon it doesn't display the data based on the json data. extras:{ data: data1 data: data2 data: data3 } for item in data['extras']: print(item)
@FarhanKhan-io3vt
@FarhanKhan-io3vt 3 года назад
Nice explanation helpful✔️
@veenawadhwa6990
@veenawadhwa6990 3 года назад
thank you very much
@santoshgiri8232
@santoshgiri8232 2 года назад
Thank you🙏😊
@ganeshprem3043
@ganeshprem3043 3 года назад
I came here because i didn't understand an unrelated example from codecademy. Thank you for clearing it up!
@ishaanmishra8868
@ishaanmishra8868 3 года назад
Same dude
@amritanshsinghgautam4001
@amritanshsinghgautam4001 4 года назад
such a nice and short video no bs just knowledge
@ComandaKronikk
@ComandaKronikk 4 года назад
"Hey Guyz WhatSuP, Chad here, before we start I wanna first do a 5009 minute intro for my sponsor ProTeINShrEDDdD"
@mehdibmc9508
@mehdibmc9508 2 года назад
Thanks 🔥
@gastonlag2693
@gastonlag2693 3 года назад
Perfect.
@abdesh3262
@abdesh3262 2 года назад
thank uu bro very much
@katrinawebbheim3772
@katrinawebbheim3772 2 года назад
3:56 indexing and slicing
@rimjhim9541
@rimjhim9541 3 года назад
What will be for negative and postive
@katrinawebbheim3772
@katrinawebbheim3772 2 года назад
5:54 why wouldn't 6 equal lobster?
@pratheekcs2237
@pratheekcs2237 2 года назад
Gratitude
@zabi_k786
@zabi_k786 4 года назад
Any hint, what to import in python programming..
@StevenSmith68828
@StevenSmith68828 4 года назад
Use opencv
@KofyImages
@KofyImages 2 года назад
But why not [-2:-5]???
@hydroUNI
@hydroUNI 4 года назад
Your list has 6 elements, this means the last element's index is 5. However in the last portion of the video you use [0:6], meaning you are slicing out of bounds of the list, since the list does not have an element with index 6. I don't get it.
@highTideWaves
@highTideWaves 3 года назад
I'm guessing it's because if you do [0:5] you are excluding the element with index 5? Although I might be wrong
@Orangelover15
@Orangelover15 3 года назад
yes i thought the samething and then went to try an example on my own. ive found that you have to add an additional number to make it completely copy the variable. So exact number for start but add plus one for the end.
@zualda4513
@zualda4513 3 года назад
Sorry for my bad english... its because the second index starts from the last value as the first one like a negetative but is'nt like reversed and the third index starts in the second in the value of the second index.
@zabi_k786
@zabi_k786 4 года назад
Hello sir I need your help I want to know how to create camera app by python..
@orion_222
@orion_222 4 года назад
gl
@N1ghtR1der666
@N1ghtR1der666 4 года назад
Slicing is so un-intuitive, it should be array[index :index] but someone though it would be a great idea to be index:index after the index????? this is clearly a bug and should be fixed.
@priyanshuanand7217
@priyanshuanand7217 3 года назад
Why dont you request for a verified sign in your channel you have completed 100 k
@milesteg8627
@milesteg8627 2 года назад
Doesn't clarify strides whatsoever
Далее
Python lists, sets, and tuples explained 🍍
15:06
Просмотров 244 тыс.
Python Decorators in 15 Minutes
15:14
Просмотров 430 тыс.
ЮТУБ ЗАБЛОКИРУЮТ В РОССИИ?
14:07
Просмотров 528 тыс.
Редакция. News: 125-я неделя
48:25
Просмотров 1,5 млн
Best Practices for Python Main Functions
11:17
Просмотров 183 тыс.
Python string slicing ✂️
11:37
Просмотров 58 тыс.
Input a List using Loops in Python
10:24
Просмотров 30 тыс.
ALL 11 LIST METHODS IN PYTHON EXPLAINED
9:23
Просмотров 79 тыс.
threading vs multiprocessing in python
22:31
Просмотров 565 тыс.
Hash Tables and Hash Functions
13:56
Просмотров 1,5 млн