A Quick Look Into JAVA

0
472

JAVA is a general-purpose object-oriented programming language, designed to have as few implementation dependencies as possible. Also referred as “write one, run anywhere” (WORA) which means that a program which has WORA capability can run anywhere regardless of the platform or machine its being run on, e.g. a java program compiled on a desktop computer with windows can also run on a mainframe with UNIX without the need to be recompiled.

Developed in the early 90’s by James Gosling at Sun Microsystems(now owned by Oracle), Java was originally designed to be used on digital devices such as mobile phones. However, with the release of version 1.0 in 1996, its main focus had shifted to the internet.

There has been many updates since version 1.0 over the years, and java has evolved as a successful programming language to be used both on and off the internet.

There are two distributions of the current implementation

  • Java Runtime Environment (JRE) – intended for the end users and contains parts of Java SE required to run java programs
  • Java Development Kit (JDK) – intended for developers and contains development tools like Java debugger, jar, compiler.

Syntax

Let us look what a basic java program contains and write a basic java program

  • Objects – an object has state and behavior. Methods display an object’s behavior, while the state of an object is stored in fields(variables).
  • Class – class in java are templates that are used to create and define objects, object methods and data types.
  • Methods – methods are basically behaviors, all the logic is written in these methods.
Now lets write a basic java program
public class FirstJavaProgram {
 public static void main(String[] args) {
        System.out.println("Hello World!");     
    }
}

This is a simple/basic java program to print “Hello World!” on the console.

Must read books on Java

. https://www.amazon.in/Head-First-Java-Brain-Friendly-Guide-ebook/dp/B009KCUX3S/ref=as_li_ss_tl?tag=guru99-21&=&slotNum=1&s=digital-text&keywords=Head+First+Java&imprToken=acM7eePixfB7.rSuTJl2og&ie=UTF8&qid=1494828071&sr=1-1&linkId=b4ab28fb6407384e46dff6517fc9b138&language=en_US

https://www.amazon.in/Effective-Java-Joshua-Bloch-ebook/dp/B00B8V09HY/ref=as_li_ss_tl?tag=guru99-21&=&slotNum=5&s=digital-text&keywords=effective+java&imprToken=OGGeRDxkFc4nRRNcVNAUdA&ie=UTF8&qid=1494828030&sr=1-1&linkId=b3dc7d7e13e56259186bb961dca599e5&language=en_US

Taimour

LEAVE A REPLY

Please enter your comment!
Please enter your name here