Python Basics Tutorial Question about Scope and Types of Variables

preview_player
Показать описание
Learn more about scope with two different types of variables

Patreon:
Github:
Discord:
Twitter:
twitter: @python_basics

#pythonprogramming #pythonbasics #pythonforever
Рекомендации по теме
Комментарии
Автор

Hello Sam! I have one question about one of your old lessons. Sorry, I am just a starter. Haha
Why do we do "sub[-1]" instead of "sub"?
"-1" is the exact point I am struggling to understand here. What exactly does the "-1" mean?
In this example, isn't "-1" the last letter of the string? (Which is not "a")
How come it is "a"?

Thank you!

baris
visit shbcf.ru