Re: [Tutor] Left Alignment -- Tkinter

2009-04-01 Thread Wayne Watson
Title: Signature.html Alan, the game changed in the thread you branched away from to other considerations. As stated there, I've thrown in the towel, but first let me say what the game was about. Here's the simplest example. Say I have four labels: small, big, house, cat, tree, and I want to pu

Re: [Tutor] toggle through a list CORRECTION

2009-04-01 Thread bob gailer
bob gailer wrote: j mercedes wrote: Hi, I have problem here...I am writing a program but I am getting stucked at how to solve the mode of a series of numbers...any ideas??? The customary approach is to collect counts of each value in a dictionary. Untested code follows: from collections imp

Re: [Tutor] toggle through a list

2009-04-01 Thread bob gailer
j mercedes wrote: Hi, I have problem here...I am writing a program but I am getting stucked at how to solve the mode of a series of numbers...any ideas??? The customary approach is to collect counts of each value in a dictionary. Untested code follows: from collections import defaultdict def

Re: [Tutor] toggle through a list

2009-04-01 Thread Emile van Sebille
j mercedes wrote: Hi, I have problem here...I am writing a program but I am getting stucked at how to solve the mode of a series of numbers...any ideas???following is the program: def mode(data): num=0 count=0 mx=0 mode=0 for i in data: i here takes on the values of data

[Tutor] toggle through a list

2009-04-01 Thread j mercedes
Hi, I have problem here...I am writing a program but I am getting stucked at how to solve the mode of a series of numbers...any ideas???following is the program:def mode(data):num=0count=0mx=0mode=0for i in data: if num!=data[i]:num=data[i]coun

Re: [Tutor] Left Alignment -- Tkinter

2009-04-01 Thread Alan Gauld
"W W" wrote Good news... I got it! Here's something that's often a good idea when debugging overlapping layouts (especially when you didn't design the parent!) - use different backgrounds! Yes, or for Frames use a relief value to see where the frame bounds are. Here's my changes (also f

Re: [Tutor] My Program stopped working, can anyone help

2009-04-01 Thread bob gailer
Jared White wrote: I am trying to produce A Caesar cipher is a simple substitution cipher , that would code For example, if the key value is 2, the word “Sourpuss” would be encoded as “Uqwtrwuu Here is my code: ( but i keep getting a ERROR) 1 - I see no indentation. Please fix that and repost

[Tutor] Fwd: range() fractional increment

2009-04-01 Thread Richard Lovely
forgot to reply-all... -- Forwarded message -- From: Richard Lovely Date: 1 Apr 2009 18:13 Subject: Re: [Tutor] range() fractional increment To: Alan Gauld There's always the itertools solution: import itertools def rangeInThirds(start,end): for whole, frac in itertools.pro

Re: [Tutor] My Program stopped working, can anyone help

2009-04-01 Thread Kent Johnson
On Wed, Apr 1, 2009 at 6:06 AM, Jared White wrote: > I am trying to produce A Caesar cipher is a simple substitution cipher , > that would code For example, if the key value is 2, the word “Sourpuss” > would be encoded as “Uqwtrwuu > > Here is my code: ( but i keep getting a ERROR) It works for me

Re: [Tutor] My Program stopped working, can anyone help

2009-04-01 Thread Padmanaban Ganesan
Hi Jared, This is program is working fine for me. Please check the indentation is proper in it. def main(): print "This program will encode your messages using a Caesar Cipher" print key = input("Enter the key: ") message = raw_input("Enter the message: ") codedMessage = "" for ch in message:

[Tutor] My Program stopped working, can anyone help

2009-04-01 Thread Jared White
I am trying to produce A Caesar cipher is a simple substitution cipher , that would code For example, if the key value is 2, the word “Sourpuss” would be encoded as “Uqwtrwuu Here is my code: ( but i keep getting a ERROR) It works for me Last week but for some reason it isnt work for me right now.