Java

An object-oriented, a cross platform programming Java Logolanguage. It is used to create stand-alone applications, net based programs and programs for consumer devices. Example : cellular phones, palm pilots Features of Java:- Simple – The Java designers removed a number of complex features that existed in C, such as pointer manipulation, operator overloading etc. Object-Oriented – Everything is an object in Java. Therefore, the focus is on the data, and the methods that operate on the object in the application instead of procedures. Platform-independent – It refers to the ability of the program at the source level, which allows the user to move the source code from one system to another, compile the code, and run it cleanly on a system. Robust – Java checks the code at the time of compilation, and also at the time of interpretation. Secure – Java provides a controlled environment for the execution of the program, for which it provides several layers of security control. Distributed – Java can be used to develop applications that are portable across multiple platforms, operating systems, and graphic user interfaces. Multithreaded – Java programs use a process called ‘multithreading’ to perform many tasks simultaneously. Swing – A new set of classes and interfaces used to create an advanced GUI with a “look and feel” design. Drag and drop – The capability to interactively transfer information across different applications and from one part of a program’s interface to another. Java 2D API – A set of classes for advanced 2D graphics and imaging. Java Sound – A totally new set of characteristics pertaining to Java’s audio features. RMI – Remote Method Invocation allows applications to call object methods located at remote sites and communicate with them.

Steps to Run Java Programs.

1. Create a java file by using text editor (Notepad) (follow the example)

class Test
{
public static void main(String h[])
{
System.out.println("Welcome to the world of JAVA by MITIndia");
}
}

2. Save the above program file as “Test.java” (same as class name)
3. Go to “Command Prompt” to do this , Click->Start->Run->Type “cmd”
4. Set your jdk path (locate your jdk or java folder, might be on C: or D: drive)
5. Type like this on the command prompt : C:\> set path=c:\jdk\bin
6. Press enter
7. Now, Compile your java file, to do this follow next step.
8. C:\>javac Test.java [Hit the enter key]
9. After successful compilation, it will create a .class file and run it as following instruction
10. C:\>java Test  [hit the enter key and you can able to see your First java program output!]

Share
Share
Scroll to Top