title: Cannot assign to value: 'i' is a 'let' constant in swift
body: <p>So basically i am trying to assign 2 random numbers up to 20 in 2 labels and the user will have to find the correct result. A different view will appear based on if the answer is correct or not and this will happen 10 times. 
  The problem is that I get an error on the counter "i" that I use and even though I declare it as variable, I get an error saying that it is a constant.</p>
  
  <pre><code>@IBAction func submit(sender: AnyObject) {
      //declarations
      var i: Int  //counter for 10 repetitions
      var result = 0
      for i in 0..&lt;10 {
          //generate 2 random numbers up to 20
          var rn1 = arc4random_uniform(20)
          var rn2 = arc4random_uniform(20)
          //assign the rundom numbers to the labels
          n1.text = String(rn1)
          n2.text = String(rn2)
          result = Int((rn1) + (rn2))
          //show respective view based on if answer is correct or not
          if answer.text == String(result)  {
              i = i + 1 //here i get the error: cannot assign to value 'i' is a 'let' constant
              performSegueWithIdentifier("firstsegue", sender: self)
          }else {
              performSegueWithIdentifier("wrong", sender: self)
          }
      }
  }
  </code></pre>