Please, someone, help me out to check the errors in this code. What is the proble? I'm new to Java applet and I'm using notepad. I copied this code from a site to test but it is not working with me in the notepad and command prompt.
import java.applet.*;
import java.awt.*;
Public class DrawExample extends Applet
{... See More
public void init()
{
bigFont=new Font("Arial",Font.Bold, 16);
redColor=Color.red;
bgColor=Color.blue;
setBackground(bgColor);
}
public void stop()
{
}
public void paint(Graphics g)
{
g.setFont(bigFont);
g.drawString("Shapes and Colors",80,20);
g.setColor(redColor);
g.drawRect(100,100,100,100);
g.fillRect(110,110,80,80);
g.setColor(weirdColor);
g.fillArc(120,120,60,60,0,360);
g.setcolor(Color.yellow);
g.drawLine(140,140,160,160);
g.setColor(Color.black);
}
}