Re: How make the judge with for loop?

2016-10-16 Thread Steven D'Aprano
On Sunday 16 October 2016 16:23, 38016226...@gmail.com wrote: > c="abcdefghijk" > len=len(c) > n is a int > sb=[[] for i in range(n)] > > while (i < len) { > for (int j = 0; j < n && i < len; j++) > sb[j].append(c[i++]); > for (int j = n-2; j >= 1 && i < len; j--)

Re: How make the judge with for loop?

2016-10-16 Thread Peter Otten
38016226...@gmail.com wrote: > c="abcdefghijk" > len=len(c) > n is a int > sb=[[] for i in range(n)] > > while (i < len) { > for (int j = 0; j < n && i < len; j++) > sb[j].append(c[i++]); > for (int j = n-2; j >= 1 && i < len; j--) // > sb[j].append(c[i

Help me!, I would like to find split where the split sums are close to each other?

2016-10-16 Thread k . ademarus
Help me!, I would like to find split where the split sums are close to each other? I have a list is test = [10,20,30,40,50,60,70,80,90,100] ​and I would like to find split where the split sums are close to each other by number of splits = 3 that ​all possible combinations and select the split

Re: pyserial: wait for execute

2016-10-16 Thread Grant Edwards
On 2016-10-16, Michael Okuntsov wrote: > is there a way, other than time.sleep(), to be sure that the command > sent through a serial port has been fully executed? If the remote device doesn't send a response telling you it's done executing the command, then there is no way to know when that has

Announcement: Code generation from state diagrams

2016-10-16 Thread peter . o . mueller
>From (UML) state diagrams to Python code made easy. State machines are without any doubt a very good way to model behavior. The new code generator from Sinelabore translates hierarchical state machines efficiently into different languages now including Python. The generator accepts diagrams fr

How to pick out the same titles.

2016-10-16 Thread Seymore4Head
How to pick out the same titles. I have a long text file that has movie titles in it and I would like to find dupes. The thing is that sometimes I have one called "The Killing Fields" and it also could be listed as "Killing Fields" Sometimes the title will have the date a year off. What I woul

Re: Help me!, I would like to find split where the split sums are close to each other?

2016-10-16 Thread breamoreboy
On Sunday, October 16, 2016 at 12:27:00 PM UTC+1, k.ade...@gmail.com wrote: > Help me!, I would like to find split where the split sums are close to each > other? > > I have a list is > > test = [10,20,30,40,50,60,70,80,90,100] > > ​and I would like to find split where the split sums are close

Re: How to pick out the same titles.

2016-10-16 Thread Alain Ketterlin
Seymore4Head writes: [...] > I have a long text file that has movie titles in it and I would like > to find dupes. > > The thing is that sometimes I have one called "The Killing Fields" and > it also could be listed as "Killing Fields" Sometimes the title will > have the date a year off. > > Wh

Build desktop application using django

2016-10-16 Thread ayuchitsaluja8
Hello I want to build a desktop application which retrieves data from server and stores data on server. I have basic experience of python and I dont know how to build that thing. -- https://mail.python.org/mailman/listinfo/python-list

Writing library documentation?

2016-10-16 Thread tshepard
Is there a standard or best way to write documentation for a particular python library? I'd mostly target HTML, I guess. Thanks! Tobiah -- https://mail.python.org/mailman/listinfo/python-list

Re: How to pick out the same titles.

2016-10-16 Thread duncan smith
On 16/10/16 16:16, Seymore4Head wrote: > How to pick out the same titles. > > I have a long text file that has movie titles in it and I would like > to find dupes. > > The thing is that sometimes I have one called "The Killing Fields" and > it also could be listed as "Killing Fields" Sometimes

Re: Build desktop application using django

2016-10-16 Thread Michael Torrie
On 10/16/2016 11:38 AM, ayuchitsalu...@gmail.com wrote: > Hello I want to build a desktop application which retrieves data from > server and stores data on server. I have basic experience of python > and I dont know how to build that thing. Crystal balls are always risky things to turn to when try

Re: Help me!, I would like to find split where the split sums are close to each other?

2016-10-16 Thread Michael Torrie
On 10/16/2016 05:25 AM, k.adema...@gmail.com wrote: > Help me!, I would like to find split where the split sums are close > to each other? > > I have a list is > > test = [10,20,30,40,50,60,70,80,90,100] > > ​and I would like to find split where the split sums are close to > each other by number

Re: How make the judge with for loop?

2016-10-16 Thread alister
On Sat, 15 Oct 2016 22:23:29 -0700, 380162267qq wrote: > c="abcdefghijk" > len=len(c) > n is a int sb=[[] for i in range(n)] > > while (i < len) { > for (int j = 0; j < n && i < len; j++) > sb[j].append(c[i++]); > for (int j = n-2; j >= 1 && i < len; j--) // >

Re: Writing library documentation?

2016-10-16 Thread Irmen de Jong
On 16-10-2016 19:41, tshep...@rcsreg.com wrote: > Is there a standard or best way to write documentation for > a particular python library? I'd mostly target HTML, I guess. > > Thanks! > > > Tobiah > I guess most people use Sphinx for this task http://www.sphinx-doc.org/ You can use various

py.test/tox InvocationError

2016-10-16 Thread D.M. Procida
When I run: py.test --cov=akestra_utilities --cov=akestra_image_plugin --cov=chaining --cov=contacts_and_people --cov=housekeeping --cov=links --cov=news_and_events --cov=vacancies_and_studentships --cov=video --cov-report=term-missing example tests it works quite happily. When I run tox -e c

Term frequency using scikit-learn's CountVectorizer

2016-10-16 Thread Abdul Abdul
I have the following code snippet where I'm trying to list the term frequencies, where first_text and second_text are .tex documents: from sklearn.feature_extraction.text import CountVectorizer training_documents = (first_text, second_text) vectorizer = CountVectorizer() vectorizer.fit_transfor

Term frequency using scikit-learn's CountVectorizer

2016-10-16 Thread Abdul Abdul
Hello, I have the following code snippet where I'm trying to list the term frequencies, where first_textand second_text are .tex documents: from sklearn.feature_extraction.text import CountVectorizer training_documents = (first_text, second_text) vectorizer = CountVectorizer() vectorizer.fit_tran

Re: Term frequency using scikit-learn's CountVectorizer

2016-10-16 Thread MRAB
On 2016-10-17 02:04, Abdul Abdul wrote: I have the following code snippet where I'm trying to list the term frequencies, where first_text and second_text are .tex documents: from sklearn.feature_extraction.text import CountVectorizer training_documents = (first_text, second_text) vectorizer = C

Re: Build desktop application using django

2016-10-16 Thread Mario R. Osorio
On Sunday, October 16, 2016 at 1:42:23 PM UTC-4, Ayush Saluja wrote: > Hello I want to build a desktop application which retrieves data from server > and stores data on server. I have basic experience of python and I dont know > how to build that thing. I agree with Martin's suspicion on you hav