[Tutor] Python Script: Downloading Youtube videos by search result

2013-04-19 Thread Sayan Chatterjee
Dear All, I want to download some music from youtube.There are already marvellous python scripts like youtube-dl which downloads videos and playlists from numerous sites,but what I want to do is to download videos from youtube with a search string. The user will give a search string, and the scrip

Re: [Tutor] path directory backslash ending

2013-04-19 Thread eryksun
On Thu, Apr 18, 2013 at 8:51 PM, Jim Mooney wrote: > > But that's in win 7. Is it okay to always omit them in Linux? Python33 > is itself installed with a trailing backslash, so I figured this was a > Linux habit. POSIX/Linux uses a forward slash instead of a backslash (py: os.sep), and the delim

[Tutor] hard time importing a module

2013-04-19 Thread Frank Schiro
hi I have a question about modules ... Im trying to use a 3rd party module called pywinatuo. It said I had to install 2 other modules. 1 was called sendkeys.py, the other was ctypes. Ctypes was included in the python library I had, but sendkeys was not. After I found SendKeys, I put it in a direc

Re: [Tutor] hard time importing a module

2013-04-19 Thread Oscar Benjamin
On 19 April 2013 15:49, Frank Schiro wrote: > hi I have a question about modules ... > > Im trying to use a 3rd party module called pywinatuo. It said I had to > install 2 other modules. 1 was called sendkeys.py, the other was ctypes. > Ctypes was included in the python library I had, but sendkeys

Re: [Tutor] hard time importing a module

2013-04-19 Thread eryksun
On Fri, Apr 19, 2013 at 11:12 AM, Oscar Benjamin wrote: > Did these files also come with a file called setup.py? > > Normally, a Python module is not installed by manually copying the > files to the appropriate places but by running 'python setup.py > install' in the terminal. This will compile an

Re: [Tutor] hard time importing a module

2013-04-19 Thread Tim Golden
On 19/04/2013 16:39, eryksun wrote: > On Fri, Apr 19, 2013 at 11:12 AM, Oscar Benjamin > wrote: >> Did these files also come with a file called setup.py? >> >> Normally, a Python module is not installed by manually copying the >> files to the appropriate places but by running 'python setup.py >> i

Re: [Tutor] hard time importing a module

2013-04-19 Thread Mark Lawrence
On 19/04/2013 16:39, eryksun wrote: On Fri, Apr 19, 2013 at 11:12 AM, Oscar Benjamin wrote: Did these files also come with a file called setup.py? Normally, a Python module is not installed by manually copying the files to the appropriate places but by running 'python setup.py install' in the

Re: [Tutor] hard time importing a module

2013-04-19 Thread eryksun
On Fri, Apr 19, 2013 at 11:52 AM, Tim Golden wrote: > As usual, the excellent Christoph Gohlke has provided binaries for a > range of targets: > > http://www.lfd.uci.edu/~gohlke/pythonlibs/ Maybe you missed the link at the end of my link fest: http://www.lfd.uci.edu/~gohlke/pythonlibs/#sendke

Re: [Tutor] hard time importing a module

2013-04-19 Thread Tim Golden
On 19/04/2013 17:12, eryksun wrote: > On Fri, Apr 19, 2013 at 11:52 AM, Tim Golden wrote: >> As usual, the excellent Christoph Gohlke has provided binaries for a >> range of targets: >> >> http://www.lfd.uci.edu/~gohlke/pythonlibs/ > > Maybe you missed the link at the end of my link fest: > >

Re: [Tutor] Hello, and a newbie question

2013-04-19 Thread Prasad, Ramit
eryksun wrote: > On Tue, Apr 16, 2013 at 7:57 PM, Virgilio Rodriguez Jr > wrote: > > Can someone please do me the favor and remove me from this god forsaken > > email list I am sorry I signed up all it has done is taken over my phone and > > rings all night long with emails I am not interested in

[Tutor] How to find reverse pair words in a list of Words that has to be accessed through a URL

2013-04-19 Thread Chetan Sai
*Here is my question:* * * *"Two words are a “reverse pair” if each is the reverse of the other. Write a program that finds all the reverse pairs in the word list. The word list can be downloaded athttp://www.puzzlers.org/pub/wordlists/pocket.txt"* ___ Tu

Re: [Tutor] How to find reverse pair words in a list of Words that has to be accessed through a URL

2013-04-19 Thread Don Jennings
On Apr 19, 2013, at 4:56 PM, Chetan Sai wrote: > Here is my question: > > "Two words are a “reverse pair” if each is the reverse of the other. Write a > program that finds all the reverse pairs in the word list. The word list can > be downloaded athttp://www.puzzlers.org/pub/wordlists/pocket.t

Re: [Tutor] How to find reverse pair words in a list of Words that has to be accessed through a URL

2013-04-19 Thread Chetan Sai
Hi Don I'm a beginner in Python Programming. I'm using python 3. I wrote a program that checks whether given two words are reverse pair or not and outputs TRUE/FALSE. *def reverse_pair(a,b):* *return list(a)==list(reversed(list(b)))* * * * * But how to write a program that finds all the reve

Re: [Tutor] How to find reverse pair words in a list of Words that has to be accessed through a URL

2013-04-19 Thread Alan Gauld
On 19/04/13 22:19, Chetan Sai wrote: I'm a beginner in Python Programming. The language isn't really the issue here the issue is the algorithm. So how would you do it manually with a paper and pen? (forget about fetching the list from the URL for now) One possibility is to use sets (Python

Re: [Tutor] How to find reverse pair words in a list of Words that has to be accessed through a URL

2013-04-19 Thread emile
On 04/19/2013 03:07 PM, Alan Gauld wrote: On 19/04/13 22:19, Chetan Sai wrote: I'm a beginner in Python Programming. The language isn't really the issue here the issue is the algorithm. So how would you do it manually with a paper and pen? (forget about fetching the list from the URL for now)

Re: [Tutor] Python Script: Downloading Youtube videos by search result

2013-04-19 Thread Amit Saha
On Fri, Apr 19, 2013 at 9:44 PM, Sayan Chatterjee wrote: > Dear All, > > I want to download some music from youtube.There are already marvellous > python scripts like youtube-dl which downloads videos and playlists from > numerous sites,but what I want to do is to download videos from youtube with

Re: [Tutor] How to find reverse pair words in a list of Words that has to be accessed through a URL

2013-04-19 Thread Alan Gauld
On 19/04/13 23:16, emile wrote: The gotcha with this approach is the border case of self paired words that aren't pairs. (pop,wow,mom,etc) yeah, but those exceptions are easy to catch as you generate the reversed list: if reversed(word) == word And its a bit of a moot point whether you sh

Re: [Tutor] How to find reverse pair words in a list of Words that has to be accessed through a URL

2013-04-19 Thread Steven D'Aprano
On 20/04/13 09:57, Alan Gauld wrote: On 19/04/13 23:16, emile wrote: The gotcha with this approach is the border case of self paired words that aren't pairs. (pop,wow,mom,etc) yeah, but those exceptions are easy to catch as you generate the reversed list: if reversed(word) == word An eas

Re: [Tutor] How to find reverse pair words in a list of Words that has to be accessed through a URL

2013-04-19 Thread Alan Gauld
On 20/04/13 01:48, Steven D'Aprano wrote: A moot point is a point which is not relevant. It most certainly is not. It is a point that is open to debate. Specifically it is a point that would be posted on the agenda for the weekly meetings in the local Moot Hall - the town guild/council's meeti