Skip to main content

Setting up java on local machine Part 1.

Introduction:-

     So to set up the JAVA development enviorment we need do some setting which are basically easy.
There can be of two setups which are the :-
     1.  Command prompt (Actually the cmd setup)

     2.  The IDE (Which are freely and licnesed)
So in this post we will be seeing the Command prompt setup.

What are the requirment for the setup?

  The requirments for the setup are the to easy there is no back techno knowledge for the setup it is the basic requirment.
  1. Internet Connection(To download the java development kit)
  2. Adminstrator privilages

Where to download the JAVA DEVELOPMENT KIT(JDK) ?

  The JDK is nothing but a set of java tools that are given in the java standard edition which are freely downloadable from the  offical oracle site the current jdk version is 11 and by the time there shall be updates to the jdk for the time being it is the 11 edition. The fully steps for the download path is as bellow

Step 1: To download rhe JDK Click Here.
Step 2: Check the download .exe file and double click on it.
Step 3: It is a simple process just click on next and the installation of the JDK will be done.

What are the enviroment varibles in the local machine?

  The enviorment varibles are nothing but the system paths which are importmant for the system to be specified for the thrid party program to be executed form anywhere .

How to setup the the enviorment variable using cmd (Command prompt) ?

  To setup the enviorment variables follow the steps bellow:-
  Step 1 : Start the cmd as Adminstrator.
  Step 2 : Type in the following command "set path= C:\<PATH to your JDK>" (Here the folder will be in the C drive and the JDK folder name is java).

    So by this you are able to setup the java enviorment on your machine to start programing your first java code . This post was all about the setup in the next post it will be the programing part where we shall see how to run a java program so stay alert for the next post.

Comments

Popular posts from this blog

Develop a program using control loops in applets.

Code: import java.awt.*; import java.applet.*; public class Control extends Applet {      public void paint(Graphics g)      {      for(int i=1;i<=4;i++)     {          if(i%2==0)         {            g.fillOval(90,i*50+10,50,50);           g.setColor(Color.black);        }        else       {          g.fillOval(90,i*50+10,50,50);          g.setColor(Color.red);       }    }   } } /* <applet code=Control width=300 height=300> </applet> */ Output:

Program to display the rate of interest of banks by method overriding method

CODE: class bank { int getroi() { return 0; } } class SBI extends bank { int getroi() { return 8; } } class ICICI extends bank { int getroi() { return 7; } } class AXIS extends bank { int getroi() { return 9; } } class EXP17Q1 { public static void main(String args[]) { SBI s = new SBI(); ICICI i = new ICICI(); AXIS a = new AXIS(); System.out.println("SBI rate of interest: "+s.getroi()); System.out.println("ICICI rate of interest: "+i.getroi()); System.out.println("AXIS rate of interest: "+a.getroi()); } } OUTPUT:

Program to calculate the room area and volume to illustrate the concept of single inheritance.

CODE: class Roomarea   { protected double l, b; Roomarea(double len, double br) { l=len; b=br; } void putdata() { System.out.println("Area of Room: "+(l*b)); } } class Roomvol extends Roomarea   { double h; Roomvol(double len, double br, double he) { super(len, br); h=he;   } void putdata() { super.putdata(); System.out.println("Volume of Room: "+(l*b*h)); } } public class EXP18Q4 { public static void main(String[] args) { Roomvol r1 = new Roomvol(10, 20, 10); r1.putdata();   } }