Re: [Tutor] env var packages

2013-05-15 Thread vasya
2013/5/15 vasya volk.vasi...@gmail.com Hi, Matthew First of all, please state what OS do you using? I think its ubuntu because some kind of this problem I've alredy solved some time ago: when I've need something like to add djando-admin.py to my PATH. What you need to do is to delete

Re: [Tutor] env var packages

2013-05-15 Thread vasya
Hi, Matthew First of all, please state what OS do you using? I think its ubuntu because some kind of this problem I've alredy solved some time ago: when I've need something like to add djando-admin.py to my PATH. What you need to do is to delete your django install that you make from

Re: [Tutor] Making a Primary Number List generator

2013-05-15 Thread Oscar Benjamin
On 14 May 2013 17:11, Marc Tompkins marc.tompk...@gmail.com wrote: The OP expressed some confusion between what a function DOES and what it RETURNS. It occurs to me that the print() function (or, more generically, ANY print() function - it doesn't have to be Python 3) is a good

Re: [Tutor] Making a Primary Number List generator

2013-05-15 Thread Steven D'Aprano
On Wed, May 15, 2013 at 10:03:20AM +0100, Oscar Benjamin wrote: On 14 May 2013 17:11, Marc Tompkins marc.tompk...@gmail.com wrote: Again, the return value of print() - e.g. success/failure - is separate from what print() actually prints. I was surprised by this so I've just tested it

Re: [Tutor] env var packages

2013-05-15 Thread eryksun
On Tue, May 14, 2013 at 3:54 PM, Matthew Ngaha chigga...@gmail.com wrote: I was instructed to get django via easy installer that was located in my Python/Scripts folder. it installed django to a different place in site-packages, where django-admin.py resides. You appear to be using Windows,

Re: [Tutor] env var packages

2013-05-15 Thread Matthew Ngaha
Thank you Vasya and Eryksun. Sorry i didn't mention my OS i am on windows. Thanks for the links and detailed explanations which after following, i now have django up and running! thanks again ___ Tutor maillist - Tutor@python.org To unsubscribe or

Re: [Tutor] Making a Primary Number List generator

2013-05-15 Thread Marc Tompkins
On Wed, May 15, 2013 at 2:26 AM, Steven D'Aprano st...@pearwood.infowrote: I assumed Marc was talking hypothetically. A print function *could* return a result, even if Python's print function does not. Actually, I was mixing up my memory of an overloaded print() function with Python's built-in

Re: [Tutor] Making a Primary Number List generator

2013-05-15 Thread Alan Gauld
On 15/05/13 16:51, Marc Tompkins wrote: Actually, I was mixing up my memory of an overloaded print() function And C's printf() returns the number of chars printed. I actually wish python had followed suit because, as Marc says, it can occasionally be useful... -- Alan G Author of the Learn

Re: [Tutor] Making a Primary Number List generator

2013-05-15 Thread Marc Tompkins
On Wed, May 15, 2013 at 1:02 PM, Alan Gauld alan.ga...@btinternet.comwrote: On 15/05/13 16:51, Marc Tompkins wrote: Actually, I was mixing up my memory of an overloaded print() function And C's printf() returns the number of chars printed. I actually wish python had followed suit because,

Re: [Tutor] Making a Primary Number List generator

2013-05-15 Thread Oscar Benjamin
On 15 May 2013 22:21, Marc Tompkins marc.tompk...@gmail.com wrote: On Wed, May 15, 2013 at 1:02 PM, Alan Gauld alan.ga...@btinternet.com wrote: And C's printf() returns the number of chars printed. I actually wish python had followed suit because, as Marc says, it can occasionally be

Re: [Tutor] Making a Primary Number List generator

2013-05-15 Thread Marc Tompkins
On Wed, May 15, 2013 at 3:43 PM, Oscar Benjamin oscar.j.benja...@gmail.comwrote: On 15 May 2013 22:21, Marc Tompkins marc.tompk...@gmail.com wrote: On Wed, May 15, 2013 at 1:02 PM, Alan Gauld alan.ga...@btinternet.com wrote: And C's printf() returns the number of chars printed. I

Re: [Tutor] Making a Primary Number List generator

2013-05-15 Thread Oscar Benjamin
On 15 May 2013 23:52, Marc Tompkins marc.tompk...@gmail.com wrote: On Wed, May 15, 2013 at 3:43 PM, Oscar Benjamin oscar.j.benja...@gmail.com wrote: On 15 May 2013 22:21, Marc Tompkins marc.tompk...@gmail.com wrote: On Wed, May 15, 2013 at 1:02 PM, Alan Gauld alan.ga...@btinternet.com

Re: [Tutor] Making a Primary Number List generator

2013-05-15 Thread Marc Tompkins
On Wed, May 15, 2013 at 3:52 PM, Marc Tompkins marc.tompk...@gmail.comwrote: I was thinking along the lines of an optional parameter (verbose or something similar), so print() would supply a return value if you asked it to but keep stumm if you didn't. After I hit Send, I thought of the

Re: [Tutor] Making a Primary Number List generator

2013-05-15 Thread Marc Tompkins
On Wed, May 15, 2013 at 4:14 PM, Oscar Benjamin oscar.j.benja...@gmail.comwrote: I don't really understand what the reason for having the information is. Would it return the number of characters written or the number of bytes? It's absolutely useless in an interactive session, or any time

Re: [Tutor] Making a Primary Number List generator

2013-05-15 Thread Alan Gauld
On 16/05/13 00:18, Marc Tompkins wrote: On Wed, May 15, 2013 at 3:52 PM, Marc Tompkins marc.tompk...@gmail.com mailto:marc.tompk...@gmail.com wrote: I was thinking along the lines of an optional parameter (verbose or something similar), so print() would supply a return value if you

[Tutor] Python Programming for the Absolute Beginner

2013-05-15 Thread Grace Kathryn
Hello~ I'm working through the Book Python Programming for the Absolute Beginner and am wondering if you could help me out with the coding to certain Challenges at the end of the book, specifically chapter 7 challenges 1 and 2 and chapter 8 challenges 1 and 3. Could you help? I need something

Re: [Tutor] changing char list to int list isn't working

2013-05-15 Thread Bhanu Pratap Singh
Hi Jim, When you replace num = int(num); it's not changing a list. Due to It only pick a value from a list. You have to pointing to list so, You have to use list[position] using while loop like below listOfNumChars = list(str(intNum)) i = 0 while i len(listOfNumChars): listOfNumChars[i]

[Tutor] Looking for python 3 tutorial

2013-05-15 Thread Sky Flyinz
Where can I find a web programming python tutorial online either book? Are social media, email, live talk, and etc that called web programming for browser? ___ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options:

Re: [Tutor] POST MULTI PART DATA WITH PYTHON

2013-05-15 Thread Japhy Bartlett
In your code, you're not actually inserting the contents of the file into your MIME part (you're only constructing headers), which is why the content-length is not right. The 404 is probably the site detecting this as a script/robot/violation of their TOS and blocking you. Which you can probably

[Tutor] question already discussed with oscar benjamin

2013-05-15 Thread Linsey Raaijmakers
Hi, Im trying to work with the help Oscar provided me, but I still get stuck :( So what I'm trying to do now is write the program with the following input and output: Input: action,start,apex,stop 3, 12, 13, 15 4, 15, 15, 15 3, 20, 21, 25 5, 21, 23, 30 ... And when you run your program it

[Tutor] python beginner-doubt

2013-05-15 Thread subha krishna
hi, i need an help in the following program i just started to learn. if speed = 80: print 'License and registration please' if mood == 'terrible' or speed = 100: print 'You have the right to remain silent.' elif mood == 'bad' or speed = 90: print I'm going to have to write you a ticket.

[Tutor] Help needed!!

2013-05-15 Thread Linsey Raaijmakers
Hello, I have a file with actions and time points at which they occur. I want to find how many times an action occurs, and how many times it occurs in combination with an other action at the same time point (overlapping between onset and apex) Below is the input file. in this file, action 50

[Tutor] (no subject)

2013-05-15 Thread Krish Nagpal
Good Afternoon, I have a quick question based on python 2.7. Do you know how to write a web server with a form. (Pthyon) When the webserver gets a GET request, I need to serve the HTML document with a form. In response to a POST, i want to write the resulting data to a form. Do you know how to do

[Tutor] Interested in learning Python

2013-05-15 Thread Raymond Jackson
Hello My name is Raymond Jackson I am currently on your tutorial site and trying to teach my self this new language I haven't done this before so i'm open to any suggestions going about this ___ Tutor maillist - Tutor@python.org To unsubscribe or

Re: [Tutor] Python Programming for the Absolute Beginner

2013-05-15 Thread Amit Saha
Hi Grace, On Thu, May 2, 2013 at 8:04 AM, Grace Kathryn grace_k_por...@earthlink.netwrote: Hello~ I'm working through the Book Python Programming for the Absolute Beginner and am wondering if you could help me out with the coding to certain Challenges at the end of the book, specifically

Re: [Tutor] Python Programming for the Absolute Beginner

2013-05-15 Thread Robert Sjoblom
I'm working through the Book Python Programming for the Absolute Beginner and am wondering if you could help me out with the coding to certain Challenges at the end of the book, specifically chapter 7 challenges 1 and 2 and chapter 8 challenges 1 and 3. Since I personally don't have that

Re: [Tutor] Making a Primary Number List generator

2013-05-15 Thread Steven D'Aprano
On 16/05/13 06:02, Alan Gauld wrote: On 15/05/13 16:51, Marc Tompkins wrote: Actually, I was mixing up my memory of an overloaded print() function And C's printf() returns the number of chars printed. I actually wish python had followed suit because, as Marc says, it can occasionally be

Re: [Tutor] python beginner-doubt

2013-05-15 Thread Dave Angel
Somehow, your message didn't appear here for 9 days. That's probably why you haven't seen any responses yet. On 05/06/2013 01:26 AM, subha krishna wrote: hi, i need an help in the following program i just started to learn. if speed = 80: print 'License and registration please'

Re: [Tutor] Interested in learning Python

2013-05-15 Thread Dave Angel
(Your message suddenly appeared here today, after four days in limbo) On 05/11/2013 08:50 AM, Raymond Jackson wrote: Hello My name is Raymond Jackson I am currently on your tutorial site Be explicit. There are lots of tutorial sites around. Perhaps you mean

Re: [Tutor] Python Programming for the Absolute Beginner

2013-05-15 Thread Matthew Ngaha
i completed this book and i did every exercise. are you asking for help with the challenges, or have you completed them and want code to compare yours too? im relunctant to share challenge code, incase you havent done them. They are really good exercises to try doing.

Re: [Tutor] Making a Primary Number List generator

2013-05-15 Thread Marc Tompkins
On Wed, May 15, 2013 at 5:07 PM, Steven D'Aprano st...@pearwood.infowrote: Guido's time machine strikes again. py import sys py sys.stdout.write('NOBODY expects the Spanish Inquisition!\n') NOBODY expects the Spanish Inquisition! 40 The write() method of file objects in Python 3 return

Re: [Tutor] Interested in learning Python

2013-05-15 Thread Matthew Ngaha
i recommend getting a copy of Python Programming for the absolute beginner. It offers end of chapter exercises to make sure you understand everything you are reading. It was a great read for me and made my learning experience really fun. I garantee by the end you would have gained a lot of

[Tutor] Bugs came home

2013-05-15 Thread Jim Mooney
Just a note about PyScripter since I was whining here about some bugs, but the bugs were mine ;') I downloaded Py 64-bit for Py 3.3 but for some reason installed 32 bit for Py 2.7. PyScripter runs multiple Pys but it apparently choked on the different word lengths. Once I installed 64 bit for

Re: [Tutor] Making a Primary Number List generator

2013-05-15 Thread eryksun
On Wed, May 15, 2013 at 8:07 PM, Steven D'Aprano st...@pearwood.info wrote: On 16/05/13 06:02, Alan Gauld wrote: And C's printf() returns the number of chars printed. I actually wish python had followed suit because, as Marc says, it can occasionally be useful... Guido's time machine