title: Updating app to swift, trying to display a percentage
body: <p>I am updating my app for swift. I am trying to display a percentage once the "calculate" button is pushed. </p>
  
  <p>So far I have:</p>
  
  <pre><code>@IBAction func calculateButton(sender: UIButton) {
          var calculated = (correctNumber / correctNumber + incorrectNumber * 100 )
          calculateLabel.text = "\(calculated)"
  
  
  
      }
  </code></pre>
  
  <p>Which I know is incorrect. How do I convert this to a percentage?</p>
  
  <p>Full code below:</p>
  
  <pre><code>import UIKit
  
  class ViewController: UIViewController {
  
      var correctNumber = 0
      var incorrectNumber = 0
      var verbalNumber = 0
      var visualNumber = 0
      var tactileNumber = 0
  
  
  
  
  //rightnumber____________________________________
  
      @IBOutlet weak var correctLabel: UILabel!
  
      @IBAction func correctUpButton(sender: UIButton) {
  
          correctNumber += 1
          correctLabel.text = "\(correctNumber)"
      }
  
      @IBAction func correctDownButton(sender: UISwipeGestureRecognizer) {
  
          correctNumber -= 1
          correctLabel.text = "\(correctNumber)"
  
      }
  //------------------------------------------------
  
  //incorrectNumber________________________________
  
      @IBOutlet weak var incorrectLabel: UILabel!
  
      @IBAction func incorrectUpButton(sender: UIButton) {
  
          incorrectNumber += 1
          incorrectLabel.text = "\(incorrectNumber)"
  
      }
  
      @IBAction func incorrectDownButton(sender: UISwipeGestureRecognizer) {
  
          incorrectNumber -= 1
          incorrectLabel.text = "\(incorrectNumber)"
  
      }
  
  //end-------------------------------------------------
  
  //verbalNumber________________________________
  
      @IBOutlet weak var verbalLabel: UILabel!
  
      @IBAction func verbalUpButton(sender: UIButton) {
  
          verbalNumber += 1
          verbalLabel.text = "\(verbalNumber)"
      }
  
      @IBAction func verbalDownButton(sender: UISwipeGestureRecognizer) {
  
          verbalNumber -= 1
          verbalLabel.text = "\(verbalNumber)"
      }
  
  
  //end-------------------------------------------------
  
  //visualNumber________________________________
  
      @IBOutlet weak var visualLabel: UILabel!
  
      @IBAction func visualUpButton(sender: UIButton) {
  
          visualNumber += 1
          visualLabel.text = "\(visualNumber)"
  
      }
  
      @IBAction func visualDownButton(sender: UISwipeGestureRecognizer) {
  
          visualNumber -= 1
          visualLabel.text = "\(visualNumber)"
  
      }
  
  
  //end-------------------------------------------------
  
  //tactileNumber________________________________________
  
      @IBOutlet weak var tactileLabel: UILabel!
  
      @IBAction func tactileUpButton(sender: UIButton) {
  
          tactileNumber += 1
          tactileLabel.text = "\(tactileNumber)"
  
      }
  
      @IBAction func tactileDownButton(sender: UISwipeGestureRecognizer) {
  
          tactileNumber -= 1
          tactileLabel.text = "\(tactileNumber)"
  
      }
  
  
  //end--------------------------------------------------
  
  //calculate______________________________________________
  
      @IBOutlet weak var calculateLabel: UILabel!
  
      @IBAction func calculateButton(sender: UIButton) {
          var calculated = (correctNumber / correctNumber + incorrectNumber * 100 )
          calculateLabel.text = "\(calculated)"
  
  
  
      }
  
  //end----------------------------------------------------
  
      //reset
      @IBAction func resetButton(sender: UIButton) {
  
          correctNumber = 0
          correctLabel.text = ""
          incorrectNumber = 0
          incorrectLabel.text = ""
          verbalNumber = 0
          verbalLabel.text = ""
          visualNumber = 0
          visualLabel.text = ""
          tactileNumber = 0
          tactileLabel.text = ""
          calculateLabel.text = ""
      }
  
  
      override func didReceiveMemoryWarning() {
          super.didReceiveMemoryWarning()
          // Dispose of any resources that can be recreated.
      }
  
  
  }
  </code></pre>