Re: newbie question

2008-08-25 Thread sharon k
>> a = int(a.replace(',', '')) > > I don't know the urllib, but I suppose if you use it to fetch content from > a web page it will return strings anyway. > > > On Aug 25, 2008, at 5:14 PM, sharon k wrote: > > >> >> thank you for your

Re: newbie question

2008-08-25 Thread sharon k
e 1, in > ValueError: invalid literal for int() with base 10: '(12 123)' > > the comma has become an empty space, it cannot be converted to an integer. > i try the above in a winxp python command line. > > > On Mon, Aug 25, 2008 at 10:48 PM, Gerhard Häring <[EMAIL P

newbie question

2008-08-25 Thread sharon k
hi all, i am new to python. i fetch a webpage with urllib, extract a few numbers in a format as follow; 10,884 24,068 my question is how to remove the comma between the number, since i have to add them up later. sorry for my bad english. -- http://mail.python.org/mailman/listinfo/python-list