1) Installation of Java software
Step 1 - Download JDK for windows using below link
https://download.oracle.com/java/22/latest/jdk-22_windows-x64_bin.exe
Step -2 Install by clicking on executable file
Step-3 After installation set the path to environment variables D:\java_inst\bin;
Step 4 : Path setting
Firstly, Right Click on “This PC”.
Click Properties.
Click “Advanced System Settings”.
Click “Environment Variables”.
In the “User Variable Section”, click the “New” button.
Enter Variable name :classpath [Don’t give space between class path] Variable
value:<directory_location>(for example in my F:\workspace\bin)
Click OK->OK->OK.
Close all windows, open a new command prompt, and run the java command
Steps to install Eclipse IDE:
1. Download and install JDK(it is a pre-requisite essential step)
2. Go to eclipse website and download choosing the version as operating system and bits requirement.
3. Open the downloaded file extension and follow the standard software installation process.
4. Choose package as per developer language needs.
5. A new window will be relaunch and if not relaunch eclipse.
6. Go to the new project and create classes inside which java applications(or programs) are good to go.
Week 1
a)
Aim : Program to display default value of all primitive datatype of JAVA
Description:
In Java, data types are used to classify different types of data that variables can hold.
They specify the size and type of values that can be stored in an identifier.
Procedure :
Create a class with name DefaultValuesDemo
Declare all primitive data types with variable names
Write main method
Inside main method display all the variables using System.out.println()
Save file name DefaultValuesDemo.java(same as class name.java which has main() )
Object Oriented Programming Through Java Page 3