Professional Documents
Culture Documents
Java (Programming Language) - Simple English Wikipedia, The Free Encyclopedia
Java (Programming Language) - Simple English Wikipedia, The Free Encyclopedia
language)
object-oriented programming language
/**
* This is a simple program
in Java.
* It shows "Hello World!"
on the screen.
*/
class HelloWorld {
public static void
main(String[] args) {
System.out.println("Hello
World!");
}
}
Benefits
Java is commonly used to teach students
how to program as a first language, but is
still also used by professionals.
Java requires that each variable be
initialized. Some older languages such
as C, allow variables to go uninitialized,
which can cause random failures with
mysterious bugs.
Java requires that each method
declares a return type—the method
should always return a value, except if
its return type is void. This also prevents
bugs.
Java comes with a large set of classes
and methods, the Java API that can be
used without having to develop as much
code "from scratch".
Unlike C, Java primitive types, such as
int, are always the same size in the
number of bits which helps achieve
cross-platform compatibility.
Java used to be thought of as being
slower than C, but that's become less
important in recent years because
computers are faster.
Java has exception-handling that
requires a programmer to handle error-
conditions such as Input/Output errors.
Code compiled on one Java platform
can be run on other platforms that
support Java without modification of
either the source-code nor the byte-
code. This means that a person can
make a Java program for a Windows
computer and have it run a Linux
computer or a Mac computer.
Criticism
Java has also been criticized. Some of the
criticisms are:
References
1. "Java SE Versions History" .
CodeJava. 4 October 2018.
2. "Java vs. C++: Which Language Is
Right For Your Software Project?" .
Hiring | Upwork. 2016-12-21. Retrieved
2018-10-05.
3. "I want to develop Android Apps —
What languages should I learn?" .
Android Authority. 2017-12-24.
Retrieved 2018-10-05.
4. "How is Java platform independent? -
GeeksforGeeks" . GeeksforGeeks.
2017-06-23. Retrieved 2018-10-05.
5. James Gosling, Henry McGilton: The
Java Language Environment. 1.2
Design Goals of the Java
Programming Language. Mai 1996.
6. The Java Language: An Overview.
James Gosling, February 1995
Other websites
Java home page
Retrieved from
"https://simple.wikipedia.org/w/index.php?
title=Java_(programming_language)&oldid=673736
6"