Follow along with the video below to see how to install our site as a web app on your home screen.
Anmerkung: This feature may not be available in some browsers.
Male dir aus Kästchenapier auf, wie ein "Gesicht" aussehen könnte.Hallo Ich soll für eine Hausaufgabe ein Gesicht in Java malen lassen, ich weiß nicht wie das geht, hätte jemand diesbezüglich einen Vorschlag, wäre wirklich nett
import java.awt.*;
public class Fenster extends Frame
{
Fenster() {
setBackground(Color.yellow);
setSize(500,500);
setLocation(500,500);
setVisible(true);
}
public static void main(String[] args) {
new Fenster();
}
}
class Kreis_1 extends Canvas {
public void paint(Graphics g) {
g.setColor (Color.red);
g.fillOval(100,100,100,100);
}
}
class EFensterK extends Frame {
EFensterK() {
add(new Kreis_1());
setBackground(Color.red);
setSize(400,400);
setVisible(true);
setLocation(200,200);
}
public static void main(String[] args) {
new EFensterK();
}
}