title: List Comprehension
body: <p>I am trying to use list comprehension and the power of the nested function to return a list of all Dates being Friday 13 within a given year in the form (dd/mm/yyyy). I am however having very little luck with nested loops, I would appreciate any assistance I could get with resolving this issue.</p>
  <p>The previously created function to be used is seen as:</p>
  <pre><code>def day_of_week11(d, m, y):
      # Write your code here
      day_names =['Monday','Tuesday','Wednesday','Thursday','Friday','Saturday','Sunday']
      if m &lt; 3:
          y -= 1
          m += 12
      m -= 2
      yd = y % 100
      yc = y // 100
      day = (d + ((13*m-1)//5) + yd + yd//4 + yc//4 - 2*yc) % 7
      day=(math.ceil(day))
      if 2&gt;day&gt;=1:
          return day_names[0]
      elif 3&gt;day&gt;=2:
          return day_names[1]
      elif 4&gt;day&gt;=3:
          return day_names[2]
      elif 5&gt;day&gt;=4:
          return day_names[3]
      elif 6&gt;day&gt;=5:
          return day_names[4]
      elif 7&gt;day&gt;=6:
          return day_names[5]
      else:
          return day_names[6]
  </code></pre>
  <p>#The function I am attempting to write now is:</p>
  <pre><code>def not_lucky (yr):
      def day_of_week11(d, m, y):
      # Write your code here
          i=(d, m, y)
      return len([i for i in range(12) if day_of_week11(d, m, y)(yr,i+1,13)==4])
  </code></pre>