Category: Java Programming

Java Programming

AWT in Java

The Abstract Window Toolkit (AWT) is a Java package that provides a set of graphical user interface (GUI) components and tools for building GUIs in Java applications. AWT is part of the Java Foundation Classes (JFC) and is one of the core technologies used for creating graphical user interfaces in Java. The AWT package includes […]

Rekha Setia 
Java Programming

ASCII in Java

ASCII ( American Standard Code for Information Interchange)  is a character encoding standard used in computers and communication equipment to represent text, control characters, and other data. ASCII was first developed in the 1960s and has been widely used since then. The ASCII standard uses a 7-bit binary code to represent each character, allowing for […]

Rekha Setia 
Java Programming

Java Virtual Machine(JVM)

JVM stands for Java Virtual Machine. It is an integral part(crucial component) of the Java Runtime Environment (JRE) and Java Development Kit (JDK). The JVM is responsible for executing Java bytecode(intermediate code), which is the compiled form of Java source code. It acts as an abstract machine that provides a runtime environment for executing Java […]

Rekha Setia 
Introduction to Java
Java Programming

Introduction to Java

Java is a high-level, object-oriented programming language(OOP (the program is divided into classes and objects)) that was developed by Sun Microsystems of USA (now owned by Oracle Corporation) in the mid-1990s. It was designed to be platform-independent, meaning that Java programs can run on any operating system or device that has a Java Virtual Machine […]

Rekha Setia 
Java Data Types
Java Programming

Java Data Types

Before we talk about data type first we know about variables because data type is used with variables. Without variables the meaning of the data type is nothing, it’s incomplete. Data types are used when you create variables in the program. Each variable is assigned a data type. The variable is the name that is […]

Rekha Setia 
Java Command Line Arguments
Java Programming

Java Command Line Arguments

In Java, command-line arguments can be passed to a program when executing it from the command line. These arguments allow you to provide inputs or configuration parameters to your Java program. Here’s how you can access command-line arguments in Java: Command-line arguments are passed to the main method of your Java program as an array […]

Rekha Setia 
Classes and Objects in Java
Java Programming

Classes and Objects in Java

Java class is a set of related objects. The object(addition a1=new addition();a1 is the object) has some attributes, whose value consists much of the state of an object. Class is a user-defined data type in Java. The complete set of data and code of an object can be made a user-defined data type with the […]

Rekha Setia 
Java Program to Calculate the Area of Rectangle
Java Programming

Java Program to Calculate the Area of Rectangle

Java program to calculate rectangle area using Scanner classes: import java.util.Scanner; public class Rarea { public static void main(String[] args) { Scanner inn = new Scanner(System.in); double height, width, area; System.out.println(“Area of Rectangle”); System.out.print(“Please enter the height: “); height = inn.nextDouble(); System.out.print(“Please enter the width: “); width = inn.nextDouble(); area = height * width; System.out.println(“Area: […]

Rekha Setia