473,385 Members | 1,830 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 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 1486
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...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

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.