Introduction to Java


What is Java ??



Java is a platform independent programming language. It is a high level, robust, object-oriented and secure programming language.


Introduction to java


Java is a powerful and versatile programming language for developing software running on mobile devices, desktop computers, and servers. Java was developed by a team led by James Gosling at Sun Microsystems. Sun Microsystems was purchased by Oracle in 2010. Originally called Oak, Java was designed in 1991 for use in embedded chips in consumer electronic appliances. In 1995, Oak was renamed Java.
It was redesigned for developing Web applications which is the one of the main reason for the popularity of java. Java has become enormously popular. Its rapid rise and wide acceptance can be traced to its design characteristics, particularly its promise that "you can write a program once and run it anywhere". Java is a full-featured, general-purpose programming language that can be used to develop robust mission-critical applications. Today, it is employed not only for Web programming but also for developing standalone applications across platforms on servers, desktop computers, and mobile devices. It was used to develop the code to communicate with and control the robotic rover on Mars. Many companies that once considered Java to be more hype than substance are now using it to create distributed applications accessed by customers and partners across the Internet.


History of java


Java Programming Language was developed by the resolution of five great people "James Gosling, Patrick Naughton, Chris Warth, Mike Sheridan and Ed Frank" but James Gosling is believed to be the inventor because he did the original design of Java and implemented its original compiler and virtual machine. They all operated for Sun Microsystems, Inc. and developed in 1991. The language took 18 months to finish and possessed an original name as “Oak” which got renamed to Java in the year 1995, due to copyright matters.


Different Versions of java:

As of 20 March 2018, both Java 8 and 11 are officially supported. Major release versions of Java, along with their release dates:

  • JDK 1.0 (January 23, 1996)
  • JDK 1.1 (February 19, 1997)
  • J2SE 1.2 (December 8, 1998)
  • J2SE 1.3 (May 8, 2000)
  • J2SE 1.4 (February 6, 2002)
  • J2SE 5.0 (September 30, 2004)
  • Java SE 6 (December 11, 2006)
  • Java SE 7 (July 28, 2011)
  • Java SE 8 (March 18, 2014)
  • Java SE 9 (September 21, 2017)
  • Java SE 10 (March 20, 2018)
  • Java SE 11 (September 25, 2018)

Popularity of Java !!!

The Internet, the Web’s infrastructure, has been around for more than forty years. HTML (Hypertext Markup Language) is a simple scripting language for laying out documents, linking documents on the Internet, and bringing images, sound, and video alive on the Web. At that time, HTML was used for the development of the web which created simple static page to view information and was less attractive and interactive. So java came into the picture. Java initially became attractive because Java programs can be run from a Web browser. Such programs are called applets.
Applets employ a modern graphical interface with buttons, text fields, text areas, radio buttons, and so on, to interact with users on the Web and process their requests. Applets make the Web responsive, interactive, and fun to use. Applets are embedded in an HTML file. Today, we can use Java to develop rich Internet applications. A rich Internet application (RIA) is a Web application designed to deliver the same features and functions normally associated with deskop applications. Java is now very popular for developing applications on Web servers.
These applications process data, perform computations, and generate dynamic Web pages. Many commercial Websites are developed using Java on the backend. So, to work on java we have different editions/platform. let check them out,


Java Editions :

Java is a full-fledged and powerful language that can be used in many ways. It comes in three editions:


Java Standard Edition (Java SE)

Java Standard Edition (Java SE) is platform to develop client-side applications. The applications can run standalone or as applets running from a Web browser. It includes Java programming APIs such as java.lang, java.io, java.net, java.util, java.sql, java.math etc.


Java Enterprise Edition (Java EE)

Java Enterprise Edition (Java EE) is a platform to develop server-side applications, such as Java servlets, JavaServer Pages (JSP),JavaServer Faces (JSF), struts, spring and hibernate. It is used in Banking application. It has advantages of the high-level security, load balancing, and clustering. In Java, EJB is used for creating enterprise applications. EJB (Enterprise Java Bean) is used to develop scalable, robust and secured enterprise applications in java.


Java Micro Edition (Java ME)

Java Micro Edition (Java ME) is a platform to develop applications for mobile devices, such as cell phones.



Look and feel of a Java program



Output:

Hey !! My First Code .
Hello Java !!


Pre-requisite

To learn Java, you must have the basic knowledge of C/C++ programming language.



Key points
  • In a java program, the semicolon is a statement terminator.
  • Java is case sensitive language. For example “println” and “Println” are different in java .
  • int, float are Keyword, it can't be used as variable name.


Do You Know?