içiçe fonksiyon örneği
This commit is contained in:
parent
2acaba9e46
commit
502d5a02d9
10
python-temel/icicefonksiyon.yerel.py
Normal file
10
python-temel/icicefonksiyon.yerel.py
Normal file
|
@ -0,0 +1,10 @@
|
|||
def foo():
|
||||
x = 10
|
||||
def bar():
|
||||
#print(x) # error
|
||||
x = 20
|
||||
print(x)
|
||||
bar()
|
||||
print(x)
|
||||
|
||||
foo()
|
10
python-temel/icicefonksiyon.yerel.py~
Normal file
10
python-temel/icicefonksiyon.yerel.py~
Normal file
|
@ -0,0 +1,10 @@
|
|||
def foo():
|
||||
x = 10
|
||||
def bar():
|
||||
print(x) # error
|
||||
x = 20
|
||||
print(x)
|
||||
bar()
|
||||
print(x)
|
||||
|
||||
foo()
|
Loading…
Reference in New Issue
Block a user