old_contents: __author__ = 'shawnmehan'
  import math
  
  """Each new term in the Fibonacci sequence is generated by adding
  the previous two terms. By starting with 1 and 2, the first 10 terms will be:
  
  1, 2, 3, 5, 8, 13, 21, 34, 55, 89, ...
  
  By considering the terms in the Fibonacci sequence whose
   values do not exceed four million, find the sum of the even-valued terms.
  """
  
  
  def fib_term(n):
      if n == 1 or n == 2: f = 1
      else: f = fib_term(n-1) + fib_term(n-2)
      return f
  
  
  def sum_even_fib_terms(ceiling):
      ft, n, s = 1, 1, 0
      while ft < ceiling:
          if ft % 2 == 0: s += ft
          n += 1
          ft = fib_term(n)
      return s
  
  print sum_even_fib_terms(4000000)
new_contents: __author__ = 'shawnmehan'
  import math
  
  """Each new term in the Fibonacci sequence is generated by adding
  the previous two terms. By starting with 1 and 2, the first 10 terms will be:
  
  1, 2, 3, 5, 8, 13, 21, 34, 55, 89, ...
  
  By considering the terms in the Fibonacci sequence whose
   values do not exceed four million, find the sum of the even-valued terms.
  """
  
  
  def fib_term(n):
      if n == 1 or n == 2: f = 1
      else: f = fib_term(n-1) + fib_term(n-2)
      return f
  
  
  def sum_even_fib_terms(ceiling):
      ft, n, s = 1, 1, 0
      while ft < ceiling:
          if ft % 2 == 0: s += ft
          n += 1
          ft = fib_term(n)
      return s
  
  print sum_even_fib_terms(4000000)
  
subject: add a line