Alan,
Thanks for the reply. This is not homework, it is a hobby. I am 44 years
old. I was using Visual Basic, but recently decided to switch to Linux and
have no intentions of going back to windows. Python seems like a good
computer language. I read somewhere the the best way to learn it was to
On Sun, Aug 23, 2009 at 10:01 PM, kreglet wrote:
>
> Alan,
>
> Thanks for the reply. This is not homework, it is a hobby. I am 44 years
> old. I was using Visual Basic, but recently decided to switch to Linux and
> have no intentions of going back to windows. Python seems like a good
> computer
On Sun, 2009-08-23 at 15:06 -0700, kreglet wrote:
> Hello,
>
> The problem that I am having is writing an algorithm for finding all the
> possible words from a given word. For example: python
>
> from "python" you can make the words pot, top, hop, not etc. There are few
> examples for making an
Hi,
I am new to the Python. I have installed Python 2.6.2 version in windows XP.
When I try to open the IDLE(Python GUI), getting the below message. Any
configuration settings required for this?
[cid:675172311@24082009-0830]
Please let me know the details.
Thanks,
Raj
<>__
Wayne,
The reason I used print sorted is that using just print throws a syntax
error:
print (lettercount.iteritems(), key=itemgetter(1)) ---> error
print lettercount.iteritems(), key=itemgetter(1) ---> error
print sorted(lettercount.iteritems(), key=itemgetter(1)) ---> works
I don't know why
Hello Mac,
Thanks for the tip.
I was aware of an and considered using it. I decided not to use it unless I
have no other choice. Although it does exactly what I am after:
a) I don't want to use any dependencies other than Python's built in
modules
b) You hit it right in the nose when you
On Mon, Aug 24, 2009 at 10:48 AM, kreglet wrote:
>
> Wayne,
>
> The reason I used print sorted is that using just print throws a syntax
> error:
>
> print (lettercount.iteritems(), key=itemgetter(1)) ---> error
> print lettercount.iteritems(), key=itemgetter(1) ---> error
> print sorted(lettercou
"kreglet" wrote
The reason I used print sorted is that using just print throws a syntax
error:
print (lettercount.iteritems(), key=itemgetter(1)) ---> error
print lettercount.iteritems(), key=itemgetter(1) ---> error
print sorted(lettercount.iteritems(), key=itemgetter(1)) ---> works
I don't
Hi Guys,
I am trying to do the following, and im not sure how to deal with a blob of
text.
I have the following file i am using as a template
%%NAME%%
%%NUMBER%%
%%REPORT%%
and i have a corresponding file with values
name="bob"
number="123"
report="report is long
and spans multiple
lines. It a
Stefan,
Have you considered a templating engine such as Jinja or Cheetah?
http://jinja.pocoo.org/2/
www.cheetahtemplate.org/
They should be able to handle a lot of the parsing and pairing of
variables in a template that you're attempting. Basically, you use
template syntax (as you seem to have c
Hello everybody,
this is more a request of info than of help.
I want to play around with pexpect a bit, but I am confused on what is
the latest stable version. On SF (linked from the site of the pexpect
developer)
http://pexpect.sourceforge.net/pexpect.html
it seems the latest version (
Stefan Lesicnik wrote:
Hi Guys,
I am trying to do the following, and im not sure how to deal with a blob of
text.
I have the following file i am using as a template
%%NAME%%
%%NUMBER%%
%%REPORT%%
and i have a corresponding file with values
name="bob"
number="123"
report="report is long
and s
Hi Raj,
I used to get this error sometimes when I was using Windows. Killing
the Python process via Task Manager and restarting IDLE was enough to
get me going but if it still remains an issue, you can run Python in
single process mode, the following is snipped from IDLE help:
"Running without a
Wayne,
> def myfunc(cmpword, mainword):
> for letter in cmpword:
> if mainword.gets(letter):
> if cmpword[letter] >mainword[letter]:
> return False
> else:
> return False
I tried your function and couldn't get it to work. It threw an error in the
line "if
14 matches
Mail list logo