Re: [Tutor] Removing Content from Lines....

2016-03-26 Thread Alan Gauld
On 26/03/16 10:08, Dimitar Ivanov wrote: > First time using the mailing list to give a suggestion, apologies in > advance if it's not appropriate :) Join the gang, any suggestions are appropriate since even when they aren't completely correct they offer learning opportunities. So all contribution

Re: [Tutor] Removing Content from Lines....

2016-03-26 Thread Dimitar Ivanov
Hello everyone, First time using the mailing list to give a suggestion, apologies in advance if it's not appropriate :) Considering you're looking for specific string, I'd recommend maybe looking into the Regular Expressions. You could use something like: #At the top of the file import re #With

Re: [Tutor] Removing Content from Lines....

2016-03-25 Thread Sam Starfas via Tutor
Thanks to all who responded. I will try the suggestions and see if I can get the rest of my script to work.Thanks again for the tips. Will also read up on "len" and "index". Cool stuff! On Thursday, March 24, 2016 5:57 PM, Sam Starfas via Tutor wrote: Hello,I am hoping you experts can

Re: [Tutor] Removing Content from Lines....

2016-03-25 Thread Alan Gauld
On 25/03/16 01:24, sina sareth via Tutor wrote: > I wonder if somebody may give some clues to write this method. > Use Django to build a view where you can download all Quotes in CSV form. Please don;t hijack another thread. Use a new post for a new question. Its not clear what you mean by Quotes

Re: [Tutor] Removing Content from Lines....

2016-03-25 Thread sina sareth via Tutor
I wonder if somebody may give some clues to write this method. Use Django to build a view where you can download all Quotes in CSV form.  Thanks On Thursday, March 24, 2016 5:55 PM, Sam Starfas via Tutor wrote: Hello,I am hoping you experts can help out a newbie.I have written some pyt

Re: [Tutor] Removing Content from Lines....

2016-03-25 Thread Peter Otten
Martin A. Brown wrote: > > Greetings Sam, > >>Hello,I am hoping you experts can help out a newbie.I have written >>some python code to gather a bunch of sentences from many files. >>These sentences contain the content: >> >>blah blah blah blah 1-up printingblah blah blah >>blah blah blah blah bl

Re: [Tutor] Removing Content from Lines....

2016-03-24 Thread Martin A. Brown
Greetings Sam, >Hello,I am hoping you experts can help out a newbie.I have written >some python code to gather a bunch of sentences from many files. >These sentences contain the content: > >blah blah blah blah 1-up printingblah blah blah blah >blah blah blah blah >blah blah Presetblah blah bla

Re: [Tutor] Removing Content from Lines....

2016-03-24 Thread Alan Gauld
On 24/03/16 21:03, Sam Starfas via Tutor wrote: > I have written some python code to gather a bunch > of sentences from many files. > These sentences contain the content: OK, They are presumably lines and not sentences. Lines end in a newline character and sentences end with a period. So they are

[Tutor] Removing Content from Lines....

2016-03-24 Thread Sam Starfas via Tutor
Hello,I am hoping you experts can help out a newbie.I have written some python code to gather a bunch of sentences from many files. These sentences contain the content: blah blah blah blah 1-up printingblah blah blah blah blah blah blah blah blah blah Presetblah blah blah blah blah blah blah P