// DrJava saved history v2 import java.awt.*; DrawingPanel p1 = new DrawingPanel(400, 200); DrawingPanel p2 = new DrawingPanel(100, 500); p1.setBackground(Color.BLUE); p2.setBackground(Color.RED); setBackground(Color.GREEN); Point pt = new Point(10, 30); pt x pt.x pt.y 3 * pt.x + 4 pt.x = 1000; pt.x pt.y pt.setLocation(10, 50); pt pt.x = 10 pt.y = 50; pt = (10, 50); pt = new Point(10, 50); pt pt pt.translate(-1, 1); pt pt.setLocation(-1, 1); pt Point pt2 = new Point(5, 7); pt pt2 pt.distance(pt2) Math.sqrt( Math.pow(pt.x - pt2.x, 2) + Math.pow(pt.y - pt2.y, 2) ) pt.distance(pt) pt2.distance(pt) pt.distance(pt2) p1 p2 DrawingPanel p3 = p1; p1.setBackground(Color.YELLOW); p3.setBackground(Color.PINK); p1 = p2; p1.setBackground(Color.YELLOW); p3 = p2; p2.setBackground(Color.GREEN); p1.setBackground(Color.BLACK); p2.setBackground(Color.BLACK); p3.setBackground(Color.BLACK); pt pt2 Point pt3 = pt; pt3 pt3.x = 1000000; pt3 pt String s = "hello there"; s s.length() s.toUpperCase() import java.util.*; Scanner console = new Scanner(System.in); String input = console.next(); input String st = new String("Hello there"); st String st = "Hello there"; st = "Hello there";