Re: [Tutor] Fw: Traceback

2014-11-18 Thread niyana morgan
Okay yeah this helping. I believe getNumber does actually return a number. On Nov 18, 2014 7:29 PM, "Danny Yoo" wrote: > On Tue, Nov 18, 2014 at 1:46 PM, wrote: > > I get this message: > > Traceback (most recent call last): > > File "C:\Program Files (x86)\Wing IDE 101 > > 5.0\src\debug\tserv

Re: [Tutor] Fw: Traceback

2014-11-18 Thread Danny Yoo
On Tue, Nov 18, 2014 at 5:01 PM, Danny Yoo wrote: > -- Forwarded message -- > From: niyana morgan > Date: Tue, Nov 18, 2014 at 4:59 PM > Subject: Re: [Tutor] Fw: Traceback > To: Danny Yoo > > > Exercise 1: > def distance(x1, y1, x2, y2): > dx = x2 - x1 > dy = y2 - y1 >

[Tutor] Fwd: Fw: Traceback

2014-11-18 Thread Danny Yoo
-- Forwarded message -- From: niyana morgan Date: Tue, Nov 18, 2014 at 4:59 PM Subject: Re: [Tutor] Fw: Traceback To: Danny Yoo Exercise 1: def distance(x1, y1, x2, y2): dx = x2 - x1 dy = y2 - y1 dsquared = dx**2 + dy**2 result = math.sqrt(dsquared) print(res

[Tutor] Fwd: Fw: Traceback

2014-11-18 Thread Danny Yoo
Forwarding to tutor. -- Forwarded message -- From: Danny Yoo Date: Tue, Nov 18, 2014 at 4:56 PM Subject: Re: [Tutor] Fw: Traceback To: niyana morgan On Tue, Nov 18, 2014 at 4:48 PM, niyana morgan wrote: > Read the link. So I need to put > Return roomWidth and roomLength? ??

Re: [Tutor] Fw: Traceback

2014-11-18 Thread Danny Yoo
On Tue, Nov 18, 2014 at 4:40 PM, Danny Yoo wrote: > On Tue, Nov 18, 2014 at 4:34 PM, niyana morgan wrote: >> Okay yeah this helping. >> I believe getNumber does actually return a number. > > > Ok. But check again. :p In your original getNumber, you may be thinking of the concept of "output v

Re: [Tutor] Fw: Traceback

2014-11-18 Thread Danny Yoo
On Tue, Nov 18, 2014 at 4:34 PM, niyana morgan wrote: > Okay yeah this helping. > I believe getNumber does actually return a number. Ok. But check again. :p You should be using a "return" statement in some part of there. Read: http://www.greenteapress.com/thinkpython/html/thinkpython00

Re: [Tutor] Fw: Traceback

2014-11-18 Thread Danny Yoo
On Tue, Nov 18, 2014 at 1:46 PM, wrote: > I get this message: > Traceback (most recent call last): > File "C:\Program Files (x86)\Wing IDE 101 > 5.0\src\debug\tserver\_sandbox.py", line 87, in > File "C:\Program Files (x86)\Wing IDE 101 > 5.0\src\debug\tserver\_sandbox.py", line 20, in main

[Tutor] Fw: Traceback

2014-11-18 Thread niyanaxx95
I get this message: Traceback (most recent call last): File "C:\Program Files (x86)\Wing IDE 101 5.0\src\debug\tserver\_sandbox.py", line 87, in File "C:\Program Files (x86)\Wing IDE 101 5.0\src\debug\tserver\_sandbox.py", line 20, in main File "C:\Program Files (x86)\Wing IDE 101 5.0\src

Re: [Tutor] How to store and use passwords?

2014-11-18 Thread boB Stepp
On Tue, Nov 18, 2014 at 9:47 AM, Alan Gauld wrote: [...] > You can roll your own password system using the crypt module. > Get each user to create a password (or give them a default) and > encrypt it with crypt. Store the result and when they log in > compare the encrypted password with the stored

Re: [Tutor] How to store and use passwords?

2014-11-18 Thread Alan Gauld
On 18/11/14 14:45, boB Stepp wrote: http://www.cyberciti.biz/python-tutorials/securely-hash-passwords-in-python/ which seemed informative, but suggests the use of the module passlib. Unfortunately, I am not allowed to install anything on the production environment, nor can anyone else. You can

[Tutor] How to store and use passwords?

2014-11-18 Thread boB Stepp
OS: Solaris 10. Python: 2.4.4 on the computer I will be doing my development work. 2.6.4 on the production environment. I am working on my first python program at work to automate a set of tasks that allows for the results of a radiotherapy plan to be compared to a set of constraints that the plan

Re: [Tutor] Trying to use the Pillow library to create a gif

2014-11-18 Thread Alan Gauld
On 18/11/14 09:24, Jason Y wrote: With these images, I'm attempting to create a gif by resizing an image (a 001.jpg) 10 times and than use a recursive function that should use the next image (a 002.jpg) and resize that 10 times, etc...; until it reaches "a 721.jpg", where it should stop. In ad

Re: [Tutor] help with tic-tac-toe program

2014-11-18 Thread Jan Erik Moström
If I understand what you're asking you need to write the current gameboard and the info you get in 'gameBoard' is the current state of the game. There are several ways of doing this (with different degrees of cleverness) but to keep it simple: Start by printing out the current state, different wa

Re: [Tutor] Trying to use the Pillow library to create a gif

2014-11-18 Thread Alan Gauld
On 18/11/14 09:24, Jason Y wrote: With these images, I'm attempting to create a gif by resizing an image (a 001.jpg) 10 times and than use a recursive function that should use the next image (a 002.jpg) and resize that 10 times, etc...; until it reaches "a 721.jpg", where it should stop. Don't

[Tutor] Trying to use the Pillow library to create a gif

2014-11-18 Thread Jason Y
Hi,~This is a university assignment I'm working on.I have approximately 720 images all using the format "a ###.jpg", where # is a number (ie. "a 001.jpg").With these images, I'm attempting to create a gif by resizing an image (a 001.jpg) 10 times and than use a recursive function that should use