[Java] I don't get new area for my program
public class Main { private int length; private int width; private int area; public Main(int l,int w){ this.length=l; this.width=w; this.area=l*w; } public void setlength(int newl){ this.length=newl; } public int getlength(){ return this.length; } public void setwidth(int neww){ this.width=neww; } public int getwidth(){ return this.width; } public int getarea(){ return this.area; } public static void main(String[] args) { Main test = new Main(1,2); System.out.println(test.getarea()); //prints the area as 2 test.setlength(5); //tried to change the length of my rectangle object System.out.println(test.getarea()); //Still prints the area as 2??????? } } I made the code above using just an online IDE. This computes the area of a rectangle. When I updated the length of my rectangle object, the area still remains the same and I don't understand why???