Java Programming Language
The Java programming language was originally developed by Sun Microsystems who first released it in 1995 as a core component of Sun Microsystems' Java Platform. This language bases much of its syntax on C and C++ but has a simpler object model and fewer low-level facilities. Most of Sun’s Java technologies are free to the public. Consumers may choose from a variety of competitive, compatible Java implementations.
A key feature of Java is "Write Once, Run Anywhere" (WORA), the promise that a program which was developed on one computer system can run similarly on other, not necessarily compatible computer systems. Java also promises to be "simple, object-oriented, and familiar", "robust and secure", "interpreted, threaded, and dynamic", and to execute with "high performance". While all these capabilities are important , WORA distinguishes Java from most other programming languages.
Java offers standardized libraries that enable programmers to access specific features such as graphics and networking for the target computers. In other words, if you want to run Java on a Windows computer you access program libraries that handle the details of communicating with the Windows graphics system.
Yes, this programming language is somewhat complicated.
Java has been accused of poor performance. To deal with this problem Java programs may generate output known as Java Bytecode that runs on a Java Virtual Machine. In theory the Java programmer need not be familiar with how Java Bytecode works, but some feel that programmer understanding of Java Bytecode improves the final product. In any case the two-stage process can lead to better performance. It must be pretty good, the number of devices that work with Java Virtual Machines was estimated at over 4 billion and that was way back in 2006.
You too can create computer games.
Sun Microsystems insists that all implementations be "compatible". In 2001 it won a $20 million judgement against Microsoft and Microsoft no longer ships Java with Windows. You can still run Java on Windows (I do but I am not a Java programmer) but access to the full suite of Java products is not a 1-2-3 operation.
Programmers traditionally start a new language by writing the Hello, world program. This program displays on the screen a single line. The Java version of Hello, world appears below:
// HelloWorld.java
public class HelloWorld {
public static void main(String[] args) {
System.out.println("Hello, world!");
}
}
In contrast the C language version of this program contains only 4 lines. XWindow is the Unix and Linux windowing system. The XWindow version of this program is more than two pages long. Clearly there is a lot happening behind the scenes.
Java applets are programs embedded in other applications, typically in a Web page displayed in a Web browser. Java servlets are similar to Java applets but run on the Web server. While Javascript is a popular, easy to use language for writing scripts (small programs) on the client computer it is not really related to the Java programming language.