On Wed, 21 Mar 2007 00:29:00 +1100, Steven D'Aprano wrote:
> On Tue, 20 Mar 2007 12:09:29 +, Doug Gray wrote:
>
>> Folks,
>> I am looking for a fast but most importantly a bullet proof method to pass
>> and NMEA data stream (GPS output) ascii numeric strings. The best I can
>> offer is:
>>
>
On Wed, 21 Mar 2007 00:29:00 +1100, Steven D'Aprano wrote:
> All your examples include spurious whitespace. If that is the only
> problem, here's a simple fix:
>
> def despace(s):
> """Remove whitespace from string s."""
> return
Gah! Ignore that stub. I forgot to delete it :(
While I
On Tue, 20 Mar 2007 12:09:29 +, Doug Gray wrote:
> Folks,
> I am looking for a fast but most importantly a bullet proof method to pass
> and NMEA data stream (GPS output) ascii numeric strings. The best I can
> offer is:
>
> def fint(a):
> try: return int(float(a))
> except: return 0
Will
Doug Gray wrote:
> Folks,
> I am looking for a fast but most importantly a bullet proof method to pass
> and NMEA data stream (GPS output) ascii numeric strings. The best I can
> offer is:
>
> def fint(a):
> try: return int(float(a))
> except: return 0
>
> The reason for this is the quality of