472,984 Members | 2,090 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,984 software developers and data experts.

Where to go from here? newbee

Just downloaded python for the fun of it.
What do I run to begin coding with?
Version 2.3.3

When I run the "command line" thing, I get a dos window.
Now what?

The built in tutor explains some basics about programming but zilch on where
to begin.
BTW, you have 357 days left to do your christmas shopping.

Jul 18 '05 #1
8 1469
On Wed, 31 Dec 2003 23:22:43 -0600, in article
<news:bt*********@enews1.newsguy.com>, Richard wrote:
Just downloaded python for the fun of it.
What do I run to begin coding with?
Version 2.3.3
Yes, unless you have some reason to use an older release.
When I run the "command line" thing, I get a dos window.
Now what?


Type some commands and see how the interpreter works.

Go to http://www.cs.unm.edu/~ej and click on these links.

Python Hacking I (Just do it!)
Python Hacking II (types, functions, exceptions)
Python Hacking III

Type the commands and see what happens.

Go to http://www.python.org/ and find some more advanced tutorials.
Jul 18 '05 #2
If you are sure you're up to it, here's a good place to start...
http://www.ibiblio.org/obp/thinkCSpy/

Wil
my 2
"When everything seems to be going well, you have obviously overlooked
something."
Richard wrote:
Just downloaded python for the fun of it.
What do I run to begin coding with?
Version 2.3.3

When I run the "command line" thing, I get a dos window.
Now what?

The built in tutor explains some basics about programming but zilch on where
to begin.
BTW, you have 357 days left to do your christmas shopping.

Jul 18 '05 #3
Wil Schultz wrote:
If you are sure you're up to it, here's a good place to start...
http://www.ibiblio.org/obp/thinkCSpy/
All nice and good for somebody with no knowledge of what a computer language
is and does.
It's like teaching 1st grade stuff to a college grad.
This tells me nothing on how to get started.
But I understand that the actual coding can be written in a text editor then
compiled?
Wil
my 2
"When everything seems to be going well, you have obviously overlooked
something."
Richard wrote:
Just downloaded python for the fun of it.
What do I run to begin coding with?
Version 2.3.3

When I run the "command line" thing, I get a dos window.
Now what?

The built in tutor explains some basics about programming but zilch on
where to begin. BTW, you have 357 days left to do your christmas
shopping.

Jul 18 '05 #4
Jules Dubois wrote:
On Wed, 31 Dec 2003 23:22:43 -0600, in article
<news:bt*********@enews1.newsguy.com>, Richard wrote:
Just downloaded python for the fun of it.
What do I run to begin coding with?
Version 2.3.3 Yes, unless you have some reason to use an older release. When I run the "command line" thing, I get a dos window.
Now what?

Type some commands and see how the interpreter works. Go to http://www.cs.unm.edu/~ej and click on these links. Python Hacking I (Just do it!)
Python Hacking II (types, functions, exceptions)
Python Hacking III Type the commands and see what happens. Go to http://www.python.org/ and find some more advanced tutorials.


Ok. Now I'm slowly understanding. I guess you could say that python is
similar to visual basic and c++ in coding.
I have a program written in python which has several "py" files included.
How do I view these for the coding examples?
Jul 18 '05 #5
On Thu, 1 Jan 2004 09:45:00 -0600, rumours say that "Richard"
<an*******@127.000> might have written:
I have a program written in python which has several "py" files included.
How do I view these for the coding examples?


..py files are the source of python programs --plain text files. Use
your favourite text editor.
--
TZOTZIOY, I speak England very best,
Ils sont fous ces Redmontains! --Harddix
Jul 18 '05 #6
Richard ....

A good way to get started with Python
is to use the interpreter in command-line mode
and experiment with it just by trying different things ....

Anything that works using the interpreter interactively
will also work by coding the commands in a text editor
and saving as a Python source file with the .py extension ....

To execute a saved program, open a DOS window,
and enter ....

python someProg.py

You may have to include your python installation directory
in the Windows path environment variable ....

set path=%path%;x:\yourPath\PythonXXX

A sample interactive session follows ....

You can copy/paste it into a text editor,
whack out the >>> and ... prompt characters,
save it as a .py file, and then execute
for a test ....

--
Cousin Stanley
Human Being
Phoenix, Arizona

# Lines beginning with the pound sign .... # are comments ....
.... #
.... # Create some named objects
.... # and bind these names
.... # to their values
.... root2 = 2**0.5
r = 42.0
x = r / root2
y = x
z = ( x**2 + y**2 )**0.5
# Define a function to print objects .... def fprint( arg ) : .... print ' ' , arg
.... # Create a list of objects .... list_objects = [ r , x , y , z ]

# Print the objects .... for this_object in list_objects : .... fprint( this_object )
....
42.0
29.6984848098
29.6984848098
42.0


Jul 18 '05 #7
Richard,

Being a newbie to Python myself, I can relate.

One way...assuming windows
Click on the python command line thing you evidently found. This gives you a dos box showing the
Python prompt...>>>
Just type Python commands: print "Hello World", for example
Control Z to exit

Another way....
Bring up a 'real' dos box, cd to Python23, or whatever your install named it, and enter python
This again shows the Python prompt >>>

From the dos prompt, you can run a Python script by entering:
python myscript.py
where myscript is a text file with an extension of py, and located in the C:\python23 dir.

If you make a sub-directory myfiles (adviable) under C:\python23, to hold your test scripts, you
need to enter:
python myfiles\myscript.py

A third way...
Use a text editor to manage files and directories, and which may be able to launch dos commands.
There are dozens of editors out there, some good, some not so good. I use PFE, and have for years.

Hope this helps a bit.

Norm

On Thu, 1 Jan 2004 09:45:00 -0600, "Richard" <an*******@127.000> wrote:
Jules Dubois wrote:
On Wed, 31 Dec 2003 23:22:43 -0600, in article
<news:bt*********@enews1.newsguy.com>, Richard wrote:

Just downloaded python for the fun of it.
What do I run to begin coding with?
Version 2.3.3
Yes, unless you have some reason to use an older release.

When I run the "command line" thing, I get a dos window.
Now what?

Type some commands and see how the interpreter works.

Go to http://www.cs.unm.edu/~ej and click on these links.

Python Hacking I (Just do it!)
Python Hacking II (types, functions, exceptions)
Python Hacking III

Type the commands and see what happens.

Go to http://www.python.org/ and find some more advanced tutorials.


Ok. Now I'm slowly understanding. I guess you could say that python is
similar to visual basic and c++ in coding.
I have a program written in python which has several "py" files included.
How do I view these for the coding examples?


Jul 18 '05 #8
On Thu, 1 Jan 2004 09:45:00 -0600, in article
<news:bt*********@enews1.newsguy.com>, Richard wrote:
Jules Dubois wrote:
> Go to http://www.cs.unm.edu/~ej and click on these links.
> Python Hacking I (Just do it!)
> Python Hacking II (types, functions, exceptions)
> Python Hacking III

> Type the commands and see what happens.


Ok. Now I'm slowly understanding.


In an earlier article, you said "It's like teaching 1st grade stuff to a
college grad." These files were created by a university senior and were
intended as quick-and-dirty "tutorials", introducing Python to a
senior-level engineering class. All were new to Python.

What I liked about the tutorials was they were instructive but required the
user to determine the correspondence between the input and output. If you
or anyone else wants the tutorials, download them now before the account is
removed. I believe the author graduated in December.
I guess you could say that python is
similar to visual basic and c++ in coding.
It's not much like Visual Basic and is perhaps somewhat similar to C++. As
I learn Smalltalk, what I'm noticing more and more is how similar they are
-- less Smalltalk's integrated environment.

Further, if you're an experienced programmer, I recommend _Python in a
Nutshell_ by Alex Martelli. I've read it cover to cover about a dozen
times now and my conclusion is that it's one of the very best programming
language books I've read (and I've read many in the last 25 years.)

Finally, download the Python documentation from Python.org.
I have a program written in python which has several "py" files included.
How do I view these for the coding examples?


..py files are source code, so load them into your favorite text editor. I
use XEmacs.
Jul 18 '05 #9

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Newbee | last post by:
Hi ! Let's say that this is the folder on the server: /web/firstDir/secondDir/images/image.gif where i have stored my pictures. I have tryed with apsolute and relative paths but i can't display...
2
by: Newbee Adam | last post by:
is it stored in a directory on hard drive, if so where? -- Adam S
9
by: EMW | last post by:
I have created a page in aspx and after a click on a button, a new page should open. How is this possible? I tried it doing it like in vb.NET with opening a new form, but it doesn't work. rg,...
8
by: ikarias | last post by:
Maybe not the right place to aske this, but a newbee (me) needs help. i trying to input a number into a textbox, so i can make a series of calculations. in the old days of basic i just jused...
2
by: Mel | last post by:
I have a selection box with 3 values. what i need is to pass 3 urls to a function that has a switch statement and based on the selection index goes on one of the tree urls. Question is how do i...
1
by: doc1355 | last post by:
I have a feeling that this is an easy question. However I'm a newbee and don't have any idea how to do this. I have three tables that stores my users information. Each user has a unique ID that is...
0
by: Martin Arvidsson, Visual Systems AB | last post by:
Hi! I have a couple of newbee questions. I have a .aspx page with a couple of TextBoxes and a submit button. Now... When i press the submitbutton i want the data in the TextBoxes to be...
2
by: Rene | last post by:
Hello to all! I am a newbee to C++, I did a beginners' course, and now I am stuck with a strange problem. I have written the function that is pasted downwards. The peculiar thing is that when...
0
by: lllomh | last post by:
Define the method first this.state = { buttonBackgroundColor: 'green', isBlinking: false, // A new status is added to identify whether the button is blinking or not } autoStart=()=>{
2
by: DJRhino | last post by:
Was curious if anyone else was having this same issue or not.... I was just Up/Down graded to windows 11 and now my access combo boxes are not acting right. With win 10 I could start typing...
0
by: Aliciasmith | last post by:
In an age dominated by smartphones, having a mobile app for your business is no longer an option; it's a necessity. Whether you're a startup or an established enterprise, finding the right mobile app...
4
NeoPa
by: NeoPa | last post by:
Hello everyone. I find myself stuck trying to find the VBA way to get Access to create a PDF of the currently-selected (and open) object (Form or Report). I know it can be done by selecting :...
3
NeoPa
by: NeoPa | last post by:
Introduction For this article I'll be using a very simple database which has Form (clsForm) & Report (clsReport) classes that simply handle making the calling Form invisible until the Form, or all...
1
by: Teri B | last post by:
Hi, I have created a sub-form Roles. In my course form the user selects the roles assigned to the course. 0ne-to-many. One course many roles. Then I created a report based on the Course form and...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 1 Nov 2023 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM) Please note that the UK and Europe revert to winter time on...
0
NeoPa
by: NeoPa | last post by:
Introduction For this article I'll be focusing on the Report (clsReport) class. This simply handles making the calling Form invisible until all of the Reports opened by it have been closed, when it...
4
by: GKJR | last post by:
Does anyone have a recommendation to build a standalone application to replace an Access database? I have my bookkeeping software I developed in Access that I would like to make available to other...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.