Write a program to create an applet and display The message "welcome to java"
Please check the tutorial Java - Applet Hello World.
In this above tutorial you will learn how to create a Java applet, compile the program and run it on the browser.
This program also teaches you how to write html code and embed the applet class in it.
You can also download the source code of this example.