Euler1 Total Divisible by 3 5
<p>Jun 25, 2012 07:55 PM
 
Sean helps...
 
def euler1 ():   note colon  then note indents  and lack of punctuation
   total=0
   nlist=[]      sets nlist to be the empty list
   for n in range(3,1000):     range gens all integers from 3 to 1000; also note the colon
       if n%30 or n%50:    n%3==0   is the test for divisibility by 3;  that's n mod 3...
           total=total+n
           if n<50:        note that colon after 50 in the condition;  for the first 50 numbers
               nlist.append(n)      append(n)
   print nlist
   print total</p>