The best way to learn Java is by practicing examples. This page has lots of examples of Java programming. You are advised to look at these examples and try them yourself.