I have created this java app to show two types of smileys, either happy or sad. :) :mad:

/*
* Programforklaring
*/
import java.awt.*;
import java.applet.*;
import static javax.swing.JOptionPane.*;
import static java.lang.Integer.*;

public class Smily extends Applet
{
char svarbokstav;
public void init()
{

}
public void paint (Graphics g)
{
String svar = showInputDialog("Vil du se ett smil? Ja/Nei");
svarbokstav = svar.charAt(0);
if(svarbokstav == 'j' || svarbokstav == 'J')
{
g.setColor(Color.YELLOW);
g.fillOval(20,40,200,200);//Head
g.setColor(Color.BLACK);
g.fillOval(65,80,30,30);
g.fillOval(150,80,30,30);//Eyes
g.fillArc(73,115,100,100,0,-180);//Mouth
g.fillArc(70,20,100,80,0,+180);//Hat
g.setColor(Color.RED);
g.fillOval(105,112,40,40);//Tounge
g.fillOval(95,195,60,20);//Nose
}
else
{
g.setColor(Color.YELLOW);
g.fillOval(20,20,200,200);
g.setColor(Color.BLACK);
g.fillOval(65,60,30,30);
g.fillOval(150,60,30,30);
g.drawArc(73,125,100,100,0,+180);
g.fillArc(70,0,100,80,0,+180);

}


}
}