[Tutor] Scraping Wikipedia Table (The retruned file is empty)

bruce badouglas at gmail.com
Tue Oct 27 06:13:53 EDT 2015


my $0.02 for what it might be worth..

You have some people on the list who are straight out begineers   who
might be doing cut/copy/paste from 'bad code'. You have people coming
from other languages.. and then you have some who are trying to 'get
through' something, who aren't trying to be the dev!! And yeah, more
time, could easily (in most cases) provide an answer, but sometimes,
you just want to get a soln, and move on to the other 99 probs (no
offense jay z!!)

you guys have been a godsend at times!

thanks - keep up the good fight/work.



On Sun, Oct 25, 2015 at 9:56 PM, Alan Gauld <alan.gauld at btinternet.com> wrote:
> On 24/10/15 00:15, Mark Lawrence wrote:
>
>>> Looking more at the code...
>>>
>>>      > for x in range(len(drama_actor)):
>>>
>>> This looks unusual...
>>
>>
>> A better question IMHO is "where did you learn to write code like that
>> in the first place", as I've seen so many examples of this that I cannot
>> understand why people bother writing Python tutorials, as they clearly
>> don't get read?
>>
>
> I think its just a case of bad habits from other languages being
> hard to shake off. If your language doesn't have a for-each operator then
> its hard to wrap your brain around any other kind of for loop
> than one based on indexes.
>
> It's a bit like dictionaries. They are super powerful but beginners coming
> from other languages nearly always start out using
> arrays(ie lists) and trying to "index" them by searching which
> is hugely more complex, but it's what they are used too.
>
> JavaScript programmers tend to think the same about Python
> programmers who insist on writing separate functions for
> call backs rather than just embedding an anonymous function.
> But Python programmers are used to brain dead lambdas with
> a single expression so they don't tend to think about
> embedding a full function. Familiarity with an idiom makes
> it easier to stick with what you know than to try something new.
>
> --
> Alan G
> Author of the Learn to Program web site
> http://www.alan-g.me.uk/
> http://www.amazon.com/author/alan_gauld
> Follow my photo-blog on Flickr at:
> http://www.flickr.com/photos/alangauldphotos
>
>
>
> _______________________________________________
> Tutor maillist  -  Tutor at python.org
> To unsubscribe or change subscription options:
> https://mail.python.org/mailman/listinfo/tutor


More information about the Tutor mailing list