global variables
If I have a global variable N, how can i set N = smth inside of defined function?
def foo()
N = 10
doesn't change global N, because Sage makes N local variable.
add a comment
If I have a global variable N, how can i set N = smth inside of defined function?
def foo()
N = 10
doesn't change global N, because Sage makes N local variable.
Does any online documentation about Python global variables help? Here is a typical stackoverflow question about them...
Not that you should necessarily make global variables in this way...
Asked: 13 years ago
Seen: 3,129 times
Last updated: Apr 04 '12