Re: [Tutor] Installing Python and modules

2011-12-19 Thread Jugurtha Hadjar
On 15/12/2011 01:28, Sean Baumgarten wrote: Hello, I'm wondering if someone could walk me step-by-step through installing Python and some third-party modules. I've never used Python or other programming languages before, but I'm just trying to install it so I can run a simple script. I'm

[Tutor] Request for guidance about a python syntax

2011-12-19 Thread Ganesh Borse
Dear Tutors, I am new to python. I am trying to understand ( use) the python implementation of goertzel implementation provided on http://www.black-aura.com/blog/2011/12/10/python-implementation-of-the-goertzel-algorithm-dtmf-decoding/ . This python program uses unpack_from() function to unpack

Re: [Tutor] Request for guidance about a python syntax

2011-12-19 Thread Jerry Hill
On Mon, Dec 19, 2011 at 10:54 AM, Ganesh Borse bganes...@gmail.com wrote: I could know the use of unpack_from, but I could not understand the fmt part, i.e *%dH % nframes * nchannels*. Can you pls help me know, what is the purpose of two % signs in this statement? That's python's string

[Tutor] A few Python Mysteries

2011-12-19 Thread Wayne Watson
Win 7, 64-bit I had Py 2.5 installed on my PC earlier this year, and it began failing around June. I finally uninstalled it, and tried 2.6. Still had problems that centered around getting to IDLE. Uninstalled 2.6, and went to 2.7. Same problem. I completely uninstalled 2.7. I do have several

Re: [Tutor] A few Python Mysteries

2011-12-19 Thread James Reynolds
On Mon, Dec 19, 2011 at 11:35 AM, Wayne Watson sierra_mtnv...@sbcglobal.net wrote: Win 7, 64-bit I had Py 2.5 installed on my PC earlier this year, and it began failing around June. I finally uninstalled it, and tried 2.6. Still had problems that centered around getting to IDLE.

Re: [Tutor] Request for guidance about a python syntax

2011-12-19 Thread Peter Otten
Jerry Hill wrote: On Mon, Dec 19, 2011 at 10:54 AM, Ganesh Borse bganes...@gmail.com wrote: I could know the use of unpack_from, but I could not understand the fmt part, i.e *%dH % nframes * nchannels*. Can you pls help me know, what is the purpose of two % signs in this statement?

Re: [Tutor] Request for guidance about a python syntax

2011-12-19 Thread Jerry Hill
On Mon, Dec 19, 2011 at 12:10 PM, Peter Otten __pete...@web.de wrote: Close, but % and * have the same operator precedence. Therefore the expression %dH % nframes * nchannels is evaluated as (%dH % nframes) * nchannels Thanks Peter, that's exactly correct. Maybe this will teach me not

Re: [Tutor] A few Python Mysteries

2011-12-19 Thread Wayne Watson
On 12/19/2011 8:50 AM, James Reynolds wrote: On Mon, Dec 19, 2011 at 11:35 AM, Wayne Watson sierra_mtnv...@sbcglobal.net wrote: Win 7, 64-bit I had Py 2.5 installed on my PC earlier this year, and it

Re: [Tutor] A few Python Mysteries

2011-12-19 Thread James Reynolds
On Mon, Dec 19, 2011 at 2:21 PM, Wayne Watson sierra_mtnv...@sbcglobal.netwrote: On 12/19/2011 8:50 AM, James Reynolds wrote: On Mon, Dec 19, 2011 at 11:35 AM, Wayne Watson sierra_mtnv...@sbcglobal.net wrote: Win 7, 64-bit I had Py 2.5 installed on my PC earlier this year, and it

[Tutor] Python challenge and decryption

2011-12-19 Thread Joaquim Santos
Hi list! This is my first post here but I've been following the list for some time now! I know that recently there was a message about decryption and all. I think that was what made me go back into the Python challenge and try to solve some of them... For the second one, I first laid on paper my

Re: [Tutor] A few Python Mysteries

2011-12-19 Thread Prasad, Ramit
James wrote: In windows 7, 1. Go to start 2. Right click on Computer 3. Select Properties. This will bring up the System menu. 4. Select Advanced system Settings on the left hand side. 5. In this new window, select Environment variables... at the bottom 6. In the bottom window area, scroll down

Re: [Tutor] A few Python Mysteries

2011-12-19 Thread Steven D'Aprano
Wayne Watson wrote: Win 7, 64-bit I had Py 2.5 installed on my PC earlier this year, and it began failing around June. I finally uninstalled it, and tried 2.6. Still had problems that centered around getting to IDLE. Uninstalled 2.6, and went to 2.7. Same problem. I completely uninstalled

Re: [Tutor] A few Python Mysteries

2011-12-19 Thread Wayne Watson
1. Go to start 2. Right click on Computer 3. Select Properties. This will bring up the System menu. 4. Select Advanced system Settings on the left hand side. 5. In this new window, select Environment variables... at the bottom 6. In the bottom window area, scroll down until you find PATH 7.

Re: [Tutor] PYTHONPATH (Mac OS X)

2011-12-19 Thread Stayvoid
Please clarify, or expand, or tell us what problem you are having or trying to solve. Hi! I want to have a possibility to import modules from the folder, which is not included in the load path. Example: module.py - def testfunc(name): file = open(name) return

Re: [Tutor] A few Python Mysteries

2011-12-19 Thread Wayne Watson
On 12/19/2011 3:19 PM, Steven D'Aprano wrote: Wayne Watson wrote: Win 7, 64-bit I had Py 2.5 installed on my PC earlier this year, and it began failing around June. I finally uninstalled it, and tried 2.6. Still had problems that centered around getting to IDLE. Uninstalled 2.6, and went

Re: [Tutor] A few Python Mysteries

2011-12-19 Thread Wayne Watson
The PATH variable for me (user) has c:\Users\Wayne\g95\bin On 12/19/2011 12:25 PM, Prasad, Ramit wrote: James wrote: In windows 7, 1. Go to start 2. Right click on Computer 3. Select Properties. This will bring up the System menu. 4. Select Advanced system Settings on the left hand side. 5. In

Re: [Tutor] Request for guidance about a python syntax

2011-12-19 Thread Ganesh Borse
Hi, That's amazing. Thanks for sharing this information. Regards On Tue, Dec 20, 2011 at 2:31 AM, Jerry Hill malaclyp...@gmail.com wrote: On Mon, Dec 19, 2011 at 12:10 PM, Peter Otten __pete...@web.de wrote: Close, but % and * have the same operator precedence. Therefore the expression %dH

Re: [Tutor] PYTHONPATH (Mac OS X)

2011-12-19 Thread Dave Angel
On 12/19/2011 08:33 PM, Stayvoid wrote: Please clarify, or expand, or tell us what problem you are having or trying to solve. Hi! I want to have a possibility to import modules from the folder, which is not included in the load path. Example: module.py - def testfunc(name): file =

Re: [Tutor] A few Python Mysteries

2011-12-19 Thread Dave Angel
On 12/19/2011 08:47 PM, Wayne Watson wrote: The PATH variable for me (user) has c:\Users\Wayne\g95\bin By top-posting, you've ruined the whole continuity of what you quoted. Anyway, with a PATH like that, you won't be able to type Python at a command prompt. It works much better if it's on

Re: [Tutor] A few Python Mysteries

2011-12-19 Thread Wayne Watson
It became apparent during the other part of this thread that I had not uninstalled Python 2.7, as I thought I had. As pointed out in the PATH discussion (James R.), the last item in the system variable PATH was Python25. I would think then changing it to Python27 might Python rolling again.