And also, I higly recommend against using lists named list. That means
overwriting builtin list object.
2011/10/12 Andreas Perstinger
> On 2011-10-12 13:15, selahattin ay wrote:
>
>>
>> hi all, I wrote these codes but the program must write the prints to a
>> text file...
>> code = [100, 200, 3
On 2011-10-12 13:15, selahattin ay wrote:
hi all, I wrote these codes but the program must write the prints to a text
file...
code = [100, 200, 300, 400, 500]
list= []
a = 0
while a< 9:
a+=1
list.append(a)
last_list = [[int(str(i) + str(k)) for i in code] for k in list]
list2= []
On Tue, 19 Jun 2007 05:15:17 -0700, ferrad <[EMAIL PROTECTED]> wrote:
> I have not used Python before, but believe it may be what I need.
>
> I have large text files containing text, numbers, and junk. I want to
> delete large chunks process other bits, etc, much like I'd do in an
> editor, but wa
ferrad wrote:
> I have not used Python before, but believe it may be what I need.
>
> I have large text files containing text, numbers, and junk. I want to
> delete large chunks process other bits, etc, much like I'd do in an
> editor, but want to do it automatically. I have a set of generic
>
ferrad wrote:
> I have large text files containing text, numbers, and junk. I want to
> delete large chunks process other bits, etc, much like I'd do in an
> editor, but want to do it automatically.
> Question: can I translate these types of rules into programmatical
> constructs that Python can
ferrad wrote:
> I have not used Python before, but believe it may be what I need.
>
> I have large text files containing text, numbers, and junk. I want to
> delete large chunks process other bits, etc, much like I'd do in an
> editor, but want to do it automatically. I have a set of generic
> r
Peter Hansen wrote:
> Gopal wrote:
>> [...] I'm
>> thinking of going with this format by having "Param Name - value". Note
>> that the value is a string/number; something like this:
>>
>> PROJECT_ID = "E4208506"
>> SW_VERSION = "18d"
>> HW_VERSION = "2"
>>
>> In my script, I need to parse
Gopal wrote:
>Thanks for the reference. However, I'm not understanding how to use it.
>Could you please provide with an example? Like I open the file, read
>line and give it to parser?
>
>Please help me.
>
>
>
I had thought of recommending what Peter Hansen recommended - just
importing the text
Thank you very much. That works!!!
--
http://mail.python.org/mailman/listinfo/python-list
Gopal wrote:
> Hello,
>
> I'm Gopal. I'm looking for a solution to the following problem:
>
> I need to create a text file config.txt having some parameters. I'm
> thinking of going with this format by having "Param Name - value". Note
> that the value is a string/number; something like this:
>
Thanks for the reference. However, I'm not understanding how to use it.
Could you please provide with an example? Like I open the file, read
line and give it to parser?
Please help me.
--
http://mail.python.org/mailman/listinfo/python-list
Gopal wrote:
>Hello,
>
>I'm Gopal. I'm looking for a solution to the following problem:
>
>I need to create a text file config.txt having some parameters. I'm
>thinking of going with this format by having "Param Name - value". Note
>that the value is a string/number; something like this:
>
>PROJEC
The ConfigParser class is designed for this task, see
http://docs.python.org/lib/module-ConfigParser.html
--
http://mail.python.org/mailman/listinfo/python-list
13 matches
Mail list logo