package com.brmuncey.shortcutcalculator.Model;

public class Calculator {

    private double value;

    public Calculator(){ value = 0; }

    public Calculator(double value) { this.value = value; }

    public void add(double x) { value += x; }

    public void subtract(double x) { value -= x; }

    public void divide(double x) { value = value / x;}

    public void multiply(double x) { value = value * x; }

    public double getValue() { return value; }
}

@@ -95,31 +95,24 @@
 value;%0A%0A    
-public 
 Calculator()
@@ -211,29 +211,38 @@
  add(double 
-x) %7B 
+value) %7B this.
 value += x; 
@@ -238,17 +238,21 @@
 alue += 
-x
+value
 ; %7D%0A%0A   
@@ -276,29 +276,38 @@
 ract(double 
-x) %7B 
+value) %7B this.
 value -= x; 
@@ -303,17 +303,21 @@
 alue -= 
-x
+value
 ; %7D%0A%0A   
@@ -339,37 +339,46 @@
 vide(double 
-x) %7B 
+value) %7B this.
 value = 
 value / x;%7D%0A
@@ -369,16 +369,21 @@
 e = 
+this.
 value / 
 x;%7D%0A
@@ -378,17 +378,21 @@
 value / 
-x
+value
 ;%7D%0A%0A    
@@ -423,21 +423,30 @@
 ble 
-x) %7B 
+value) %7B this.
 value = 
 valu
@@ -445,16 +445,21 @@
 e = 
+this.
 value * 
 x; %7D
@@ -458,9 +458,13 @@
 e * 
-x
+value
 ; %7D%0A

Refactor Calculator