Java-Explanation of First Program

Program   Class Declaration The first line class Javaapp declares a class, which is an object-oriented construct. Java is a true object-oriented language and therefore, everything must be placed inside a class. class is a keyword and declares that a new class definition follows. Javaapp is a Java identifier that specifies the name of the … Read more…

Java-Print and Println

Print and Println The print() method prints just the string, but does not move to a new line. The println() method prints the string and moves to a new line. Program Program Source class Javaapp { public static void main(String[] args) { System.out.print(“Java is a high-level programming “); System.out.println(“language originally developed by “); System.out.print(“Sun Microsystems and released … Read more…

Java-String Concatenation

String Concatenation To join two String objects to form a new, single string you use the + operator, just as you have been doing with the argument to the println() method in the program example thus far. Program Program Source class Javaapp { public static void main(String[] args) { System.out.println(“hajsof”+”java”+”tutorial”); } }

Java-Implementing Java Program

Implementing Java Program Implementation of a Java application program involves a series of steps. They include : Creating the program Compiling the program Running the program Creating the program We can create a program using any text editor. Assume that we have entered the following program : class Javaapp { public static void main(String[] args) … Read more…

Java-Installing and Configuring Java

Installing and Configuring Java The first step in the installation of Java is to download the Java Development Kit(JDK) from the java.sun.com website. We must choose the right version of Java at the time of download keeping in mind the existing platform. Once the set up file is downloaded, we may proceed to install Java. … Read more…

Java-Java Programming

Introduction Java is a general-purpose, object-oriented programming language developed by Sun Microsystems of USA in 1991. Java was designed for the development of software for consumer electronic devices TVs, DVD players and such other electronic machines. Java a really simple, reliable, portable, and powerful language. The most striking feature of the language is that it … Read more…