On Mon, 2009-02-02 at 11:31 +, etrade.griffi...@dsl.pipex.com wrote:
> Hi
>
> I am trying to read data from a file that has format
>
> item_name num_items item_type items
>
> eg
>
> TIME 1 0.0
> DISTANCE 10 0.0 1.0 2.0 3.0 4.0 5.0 6.0 7.0 8.0 9.0
> TIME 1 1.0
> DISTANCE
On Wed, 2009-01-21 at 23:31 -0500, bob gailer wrote:
> Depends on your knowledge of Python and (if any) CMS Pipelines.
>
> Testing
> Design critique (devil's advocate)
> Cleaning up and fine-tuning the parser
> Coding built-in stages
> Documentation
> Financial support
>
> Let me know what spark
>>>a = '1234 5678 1 233 476'
>>>a.split()
['1234', '5678', '1', '233', '476']
Where the '>>>' are the command prompt from python. Don't type those.
A space is the default split delimiter. If you wish to use a '-' or new
line feed them as strings to the split method.
John
On Wed, 2009-01-21 at
On Sun, 2009-01-18 at 10:37 -0500, David wrote:
> Everything else works + - / but not *
> why?
> thanks
> -david
>
>
> #!/usr/bin/python
> from __future__ import division
> import sys
>
>
> def add(x, y):
> return x + y
> def sub(x, y):
> return x - y
> def dev(x, y):
> return x
On Thu, 2009-01-15 at 12:19 +1000, Mr Gerard Kelly wrote:
> Thanks very much
>
> I've noticed that the eval() function gives an integer, so eval("3/2")
> gives back 1. float(eval("3/2")) doesn't seem to work, any way to get a
> floating point number back with eval()?
>
> I know you can just do ("
Try eval("2*3")
On Thu, 2009-01-15 at 10:14 +1000, Mr Gerard Kelly wrote:
> If you have a string "6", and you do int("6"), you get the number 6.
>
> But if you have a string "2*3" and you do int("2*3") you get a name error.
>
> How do you take an expression in a string, and evaluate the expressi
On Sun, 2009-01-11 at 14:01 -0800, rev pacce wrote:
> I have no expierence using python. I was following a tutorial and i
> kept getting a syntax error. it was >>> print "hello world!" hello
> world was not coming up underneath it.. i tried to run the module but
> that didnt work either.
>
> __
Despite the name I believe Winpdb is platform independent I haven't
used it myself but I looked into it while following this thread.
http://winpdb.org/
John Purser
On Sat, 2009-01-10 at 12:56 +0100, Michael Bernhard Arp Sørensen wrote:
> It might and I'll keep it in mind.
>
> However, I'm not
On Wed, 2009-01-07 at 18:12 -0800, Artie Ziff wrote:
> Hello,
>
> I used python list comprehension to create a grid (list of lists) of
> Objects (instances of MyItem class). Can anyone make recommendations to
> achieve a simple access to the elements. My attempt at array access
> (like this: array
On Mon, 2009-01-05 at 18:49 +0530, vanam wrote:
> Hi all,
> i am beginner to this python language and slowing learning the
> language by referring docs.I am trying to understand the for loop
> i.e., usage of for loop in python,unlike c where i can give condition
> in python it is simple iterating o
On Thu, 2009-01-01 at 09:34 -0500, Kent Johnson wrote:
> For several years I have been using a simple script to find the top 20
> posters to the tutor list by web-scraping the archive pages. I thought
> others might be interested so here is the list for 2008 and the script
> that generates it. The
On Thu, 2009-01-01 at 15:07 +0100, Christopher Mutel wrote:
> Hello all-
>
> I stumbled across some discussion of why the fundamental difference
> between lists and tuples is not mutability, but hetero- versus
> homogeneous data, e.g.
>
> http://jtauber.com/blog/2006/04/15/python_tuples_are_not_j
12 matches
Mail list logo