I\'ve been trying to initialize an array and then test its values with a class method. I have initialized the array and have already tested it successfully within the constr
Your problem is with this line:
boolean[] grid = new boolean[sides];
This is initializing a local variable grid, not the field in the instance.
Change it to:
grid = new boolean[sides];
This initializes the field in the instance.
By putting the type in front you are declaring a new variable. When you declar a variable in a method its scope is limited to that method. Since your local variable is named the same as your instance variable it "hides" the instance variable.