Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

My question is based on this article.

My Wikipedia lens is working well and this article is very nice. But I don't understand, what is this string doing:

for article in self.wikipedia_query(search):

I want to link my Lens with Google AJAX Search API, but my code is don't working.

share|improve this question

You have a basic understanding of Python, right?

It's a basic for-loop which iterates over the return value of the wikipedia_query() method and stores it as article for each iteration. Same as each simple loop, like:

for x in range(4):
    print x
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.