Hi Dotan,
Just for reference, the weirdness that you're seeing before the email
addresses in your text file are "MIME-encoded" strings.
http://en.wikipedia.org/wiki/MIME
Concretely, the string
"=?UTF-8?B?157XqNeZ15Qg15nXoNeY16bXnw==?="
is an encoding of a string in MIME format, and
> anchors = soup.findAll('a', { 'name' : re.compile('^A.*$')})
> for x in anchors:
>print x
>x = x.next
>while getattr(x, 'name') != 'a':
> print x
> And get into endless loops. I can't help thinking there are simple and
> obvious ways to do this, probably many, but as a rank beg
Hi Teresa,
Has anyone on this thread already suggested the 'fileinput' module? From
what I understand, what 'fileinput' does is exactly what you're asking
from:
http://mail.python.org/pipermail/tutor/2007-April/053669.html
Here's documentation on 'fileinput':
http://www.python.org/
> If this is homework, please tell your teacher I helped - I need the
> extra credit.
Please avoid giving homework answers like this. Rather than actually help
the person, it can do harm, because it encourages a lazy attitude toward
solving problems.
___
> a socket. Right now, I am pickling a basic string base 64 encoding and
> sending the data over the network. After the recipient client/server
> receives the data, it is decoded and then unpickled. The unpickling
> fails with an EOFError, and I am not sure why.
Hi Adam,
Did you "flush" the
>> I thought when I read the 2002 thread with the subject (Creating an
>> Identifier or Object Name from a String?), that I had found a solution
>> to my problem.
Wait. But what was the solution you ended with? If the conclusion of
that thread was to use eval(), then that was the wrong lesso
>> Why does the identity operator return "True" in the below cases,
>> that is when assigning the same value to basic variable types
>> (float, integer, string, bool..)? Are these rcopied by reference
>> (shallow)? If so why?
>>
> i = 10
> j = 10
> i is j
>> True
The above you have
On Thu, 8 Feb 2007, Johan Geldenhuys wrote:
> OK, this what I wanted:
>
> I have a value: a = 48.41
>
> My lowValue is: lowValue = 48.35
> My highValue is : highvalue = 48.45
Range does not work on floats: it's meant to work on integers.
> I though that it could be possible to have a range b
On Tue, 6 Feb 2007, Daniel Yoo wrote:
>> this is the callee which is saved in tester.py
>> ##
>> import sys
>>
>> def main(arg):
>> if arg != []:
>> print"\nArgument is %s" % arg
On Tue, 6 Feb 2007, Tony Cappellini wrote:
> this is the caller
> ##
> callee=open("tester.py").read()
> exec(callee)
> eval("main(['', 'argument'])")
>
> ##
> this is the callee which is saved in tester.py
> ##
On Tue, 6 Feb 2007, Johan Geldenhuys wrote:
> I'm not a C++ expert at all and I would like to find out if somebody can
> explain to me how the statement below can be done in Python?
>
> """
> _uint16 ComCRC16(_uint8 val, _uint16 crc)
> {
>_uint8 i;
>_uint16 cval;
>
>for (i=0
On Mon, 5 Feb 2007, Marcus Goldfish wrote:
> I think I found the problem: the last chunk read is incomplete, so there
> is size(chunk) is not sufficient to unpack according to the format
> string.
Good! I'm glad you found the problem.
___
Tutor mai
12 matches
Mail list logo