thanks for all the useful info in this thread. it is a very good guide for the things i'm trying to learn.
currently i'm working through the python book recommended by the op. i have no previous coding experience, so it is slow but rewarding. i am having trouble opening a file in python though. here's the syntax of file "chaos.py"
Code:
def main (): print "this program illustrates chaotic function"
x = input ("enter number btwn 0 and 1: ")
for i in range (10):
x = 3.9 * x * (1-x)
print x
it runs just fine
Code:
main ()this program illustrates chaotic function
enter number btwn 0 and 1: .4
0.936
0.2336256
0.698274248196
0.821680557759
0.571434313164
0.955098841721
0.16725167263
0.543186347468
0.96772626363
0.121805355011
but when i try to call it from the command line i get issues:
Code:
python.chaos.py
Traceback (most recent call last):
File "", line 1, in
python.chaos.py
NameError: name 'python' is not defined
or if i try calling just chaos.py, similar error message:
Code:
Traceback (most recent call last): File "", line 1, in
chaos.py
NameError: name 'chaos' is not defined
what am i doing wrong?
-----------------------------------------------------------------------
also my friend recommended i learn python using codeacademy. anybody have anything to say regarding whether codeacademy or the zelle book (the one in the op) is better, or what each is better for?