title: Sum of consecutive pairs in a list including a sum of the last element with the first
body: <p>I have a list of elements like <code>[1,3,5,6,8,7]</code>.
  I want a list of sums of two consecutive elements of the list in a way that the last element is also added with the first element of the list.
  I mean in the above case, I want this list:
  <code>[4,8,11,14,15,8]</code></p>
  <p>But when it comes to the addition of the last and the first element during for loop, index out of range occurs.
  Consider the following code:</p>
  <pre><code>List1 = [1,3,5,6,8,7]
  List2 = [List1[i] + List1[i+1] for i in range (len(List1))]
  
  print(List2)
  </code></pre>