diff --git a/AndroidCalculator/Base.lproj/Main.storyboard b/AndroidCalculator/Base.lproj/Main.storyboard index 3f3d991..5e12480 100644 --- a/AndroidCalculator/Base.lproj/Main.storyboard +++ b/AndroidCalculator/Base.lproj/Main.storyboard @@ -246,7 +246,7 @@ - + diff --git a/AndroidCalculator/Calculator.swift b/AndroidCalculator/Calculator.swift index 540befe..9656303 100644 --- a/AndroidCalculator/Calculator.swift +++ b/AndroidCalculator/Calculator.swift @@ -9,14 +9,14 @@ import Foundation class Calculator { - var formula = "" + var process = "" var result = "" func click(_ text: String) { if text == "AC" { - formula = "" + process = "" } else { - formula += text + process += text } } } diff --git a/AndroidCalculator/ViewController.swift b/AndroidCalculator/ViewController.swift index 3c6fb05..be6d7bc 100644 --- a/AndroidCalculator/ViewController.swift +++ b/AndroidCalculator/ViewController.swift @@ -11,7 +11,7 @@ import UIKit class ViewController: UIViewController { @IBOutlet weak var borderView: UIView! - @IBOutlet weak var formulaLabel: UILabel! + @IBOutlet weak var processLabel: UILabel! @IBOutlet weak var resultLabel: UILabel! @IBOutlet var numberButtons: [UIButton]! @@ -23,7 +23,7 @@ class ViewController: UIViewController { } func updateView() { - formulaLabel.text = calculator.formula + processLabel.text = calculator.process resultLabel.text = calculator.result }