Question: main code public void verticalShutters() { Pixel[] pixelArray= this.getPixels(); Pixel pixel= null; Color color=null; for (int x=0; x my call to the main code public
main code public void verticalShutters() { Pixel[] pixelArray= this.getPixels(); Pixel pixel= null; Color color=null; for (int x=0; x my call to the main code public class Lab9PartB { public static void main(String [] args) { String filename; if (args.length > 0) { // got a filename passed into program as a parameter // don't change this part of the code: needed by the Autograder. filename = args[0]; System.out.println("Filename passed in: " + filename); } else { // ask user for a picture filename = FileChooser.pickAFile(); System.out.println("User picked file: " + filename); } Picture pic = new Picture(filename); // place the vertical shutters pic.verticalShutters(); pic.horizontalShutters(); // show the picture pic.show(); } } I am trying to create a checkerboard through this code but I constantly get this result instead. I was wondering what I need to change or add between the two main methods to be able to get a checkerboard. This is Java![main code public void verticalShutters() { Pixel[] pixelArray= this.getPixels(); Pixel pixel=](https://dsd5zvtm8ll6.cloudfront.net/si.experts.images/questions/2024/09/66f4f8fe19df9_55766f4f8fd526d0.jpg)
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
