@awdev_6: Python scope & return #programming #awdev_6

CodeStra
CodeStra
Open In TikTok:
Region: DZ
Tuesday 07 July 2026 18:10:54 GMT
47682
3378
36
115

Music

Download

Comments

cookster170
Michael :
Is this like local and global variables
2026-07-07 18:17:14
20
frank.com199
￴￴ ￴￴ ￴￴￴ ￴￴ ￴￴￴ ￴ :
please what are the things you can creat with python?
2026-07-07 18:18:40
4
bteccy
Btek🇵🇱 :
What if I create a function inside a function and place the variable in the first function : def main (): variable = ‘something’ def main2(): print(variable) // would this work?
2026-08-26 01:38:34
0
randombro91
MasterDiddyDihSucker :
(fix me if im wrong) you can also make arguments in the function optional by assigning the argument to a value example code: def function(text="text"): print(text) now you can use function() and it will print "text" or you can change the text by function("Hello, World")
2026-07-07 18:35:21
3
soycarolusquintae
carolusquintae :
in languages that use {}, it's better to understand scope and return values because {} delimits a block of code, and any variable you create inside can't be used outside in a general way
2026-07-07 23:06:41
1
vvindovvs
VVindovvs :
It's because of the scope and pokkor.
2026-07-11 16:00:46
0
jaybbreeezy
Jeremy :
So I’ve made a small black jack program that currently draws 2 cards and has an output of 2 card values and 2 cards, I tried def it and using it in another program with the import, but all it does is run that function, it doesn’t actually give me the info it made, is there a way to call upon information created in it?
2026-07-26 21:37:27
0
michael.gorman
Michael Gorman :
I found realdev.dev helpful for learning these concepts
2026-07-08 02:05:57
3
snm134
sam :
best explanation of return I've ever heard, now do a video comparing yield and return
2026-07-07 18:18:10
2
chocoxiv
E=mc² :
Happy birthday codestra 😁
2026-07-08 21:39:06
1
delly_chang
MiN0000R :
functions can rerurn just one value ??
2026-07-08 12:11:25
1
baidooderricktechtalk
DBX code lab :
Is this like local and global variables
2026-07-08 22:48:29
1
mohammed.al.wahid
Mohammed Al Wahidi :
🥰 Thank you
2026-07-09 15:46:39
0
mrrebo_2203
⚡ Mr.Rebooo!! ⚡ :
2026-07-07 19:02:54
2
userzfaf8eyvrb
Ras :
you are about 30 years behind
2026-07-10 23:33:09
0
votd01
VerseOfTheDay :
first!! can I get a follow?!
2026-07-07 18:12:57
2
To see more videos from user @awdev_6, please go to the Tikwm homepage.

Other Videos


About