No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.
class P3 { public static void main (String[] args) { makeP3Picture(); } public static Picture makeP3Picture(Picture source) { String fileName = FileChooser.pickAFile(); String sourceFile = FileChooser.getMediaPath("butterfly1.jpg"); Picture sourcePicture = new Picture(fileName); Picture targetPicture = new Picture(source.getWidth()*3, source.getHeight()*2); source.explore(); source.copyPhoto(); source.show(); return sourcePicture; } } im getting the error: "makeP3Picture(Picture) in … | |
I need to count the number of votes for candidates... I'm getting an unreachable statement error on "int[] array = new int[6];" Scanner sc= new Scanner(System.in); int a= sc.nextInt(); return a; int[] array = new int[6]; int mitt; mitt= array [a]; int rick; rick= array [a]; int newt; newt= array … | |
public static void main(String[] args) { World earth = new World(); Turtle t1 = new Turtle(earth); t1.penUp(); t1.moveTo(50,50); t1.penDown(); t1.setPenWidth(5); t1.drawLetterN(5.0); t1.penUp(); t1.moveTo(500,400); t1.penDown(); t1.setPenWidth(3); t1.drawLetterN(2.0); t1.penUp(); t1.moveTo(330,50); t1.penDown(); t1.setPenWidth(15); t1.drawLetterN(15.0); t1.penUp(); t1.moveTo(250,240); t1.penDown(); t1.setPenWidth(8); t1.drawLetterN(7.0); t1.penUp(); t1.moveTo(10,350); t1.penDown(); t1.setPenWidth(10); t1.drawLetterN(10.0); } public void drawLetterN (double scale) { System.out.println("drawLetterN was … | |
Java error- java:12: class, interface, or enum expected? class ProgrammingProject01 { public static void main(String blabla[]) { System.out.println("Hello"); World world1 = new World(); Turtle turtle1 = new Turtle(world1); } } public void drawN1() { this.penUp(); this.moveTo(50,50); this.penDown(); this.setPenWidth(5); this.setColor(new java.awt.Color(255, 0, 0)); this.turn(180); this.forward(50); this.turn(180); this.forward(50); this.setColor(new java.awt.Color(255, 200, 0)); … |