UrbanPro

Learn Java Training from the Best Tutors

  • Affordable fees
  • 1-1 or Group class
  • Flexible Timings
  • Verified Tutors

Search in

Why Java is platform independent?

Asked by Last Modified  

38 Answers

Learn Java

Follow 0
Answer

Please enter your answer

M-Tech

Once your java code compiled, compiled code(.class) can be executed on any os platform...if your question is HOW..it is interesting which deals with bytecode conversation
Comments

Because of JVM , JVM can be installed in any Operating system.Write once and execute anywhere(ANY OS) your code.
Comments

because java has a own runtime environment it's program is not depend on operating System. c and C++ does not have run time environment ,c & C++ program are Depend for run on OS.
Comments

Java Expert

Previously, most of the programs written in any language have had to be recompiled or rewritten for every other computer platform. Means, you have to either change your code or recompile it when you change the platform (i.e. windows or UNIX or Mac OS etc).JAVA comes with its greatest advantage that you...
read more
Previously, most of the programs written in any language have had to be recompiled or rewritten for every other computer platform. Means, you have to either change your code or recompile it when you change the platform (i.e. windows or UNIX or Mac OS etc).JAVA comes with its greatest advantage that you only have to write and compile your code once. The Java on any platform will interpret the compiled byte code (.class file) into instructions understandable by the particular processor using either interpreter or JIT compiler. JVM uses both the interpreter and JIT compiler. Note: JIT(Just In Time) do not do code compilation but the byte code compilation to platform language (Instruction set) So we can say if we have JVM available for any platform, the onetime compiled code will work on it using the WORA feature of Java i.e. Write Once Run Anywhere. read less
Comments

I think your question is "Why Java is called platform independent?"- Java lets you compile source code (written in java) on one platform say Windows and the same compiled code can run on machine with any other platform(be it unix , linux etc) having a JVM running on it. And if your question is - Why...
read more
I think your question is "Why Java is called platform independent?"- Java lets you compile source code (written in java) on one platform say Windows and the same compiled code can run on machine with any other platform(be it unix , linux etc) having a JVM running on it. And if your question is - Why Java is platform independent? Answer - Its the beauty of open source Java , that it does not discriminate between platforms. :) read less
Comments

Software Developer, Expertise in Java/J2ee Technology.

Java is platform independent, as the java compiled code (byte code) can run on any machine (Operating System) which has JVM in it. Description : JVM is platform dependent, ie JVM for different OS are different. JVM is intermediator, between Java byte code and OS and so, It converts the java byte...
read more
Java is platform independent, as the java compiled code (byte code) can run on any machine (Operating System) which has JVM in it. Description : JVM is platform dependent, ie JVM for different OS are different. JVM is intermediator, between Java byte code and OS and so, It converts the java byte code into executable code for that OS. read less
Comments

Computer wizard

because every program gets compiled forming a byte code file that can be interpreted on any platform having JAVA runtime environment JRE.
Comments

awesome

First of all, a platform is anything on which a program is run(in lay man term). A platform is either the machine itself, or a primitive kernel or a fully developed OS. Languages can be platform dependent or independent. Dependent means its executable code and source code varies from platform to platform....
read more
First of all, a platform is anything on which a program is run(in lay man term). A platform is either the machine itself, or a primitive kernel or a fully developed OS. Languages can be platform dependent or independent. Dependent means its executable code and source code varies from platform to platform. That is to say that the programmer has to make some changes in the code if it has to run on other platforms. Languages like C are platform dependent. Platform independent means that the code remains the same irrespective of the platform involved. Java has something called a virtual machine called JVM or Java Virtual Machine. What happens in case of Java is that the JVM once installed on any platform like windows or OS X can run the java code without any alteration. The JVM acts like a virtual platform on which the code is executed. As the platform being JVM remains constant throughout all platforms Java programs can run on any platform irrespective of the real platform. If you want to know the detailed process then it is here: Java source code written in the high level java is first converted to something called the javabyte code. This byte code is not readable by the original platform, but only the JVM can read it and then it executes it. This is the primary reason why Java is much in use even today. read less
Comments

Most Advanced Java training in Ahmedabad

Because once you compile Java code the binaries / class file generated are not machine dependent instead they contain byte code which at the time of execution translated to respective machine code by the JVM(Java virtual machine)
Comments

One of the major features of java includes that why java is called platform independent language. Before understanding this feature we need to know about -- Javac -- compiler that converts source code to byte code. JVM- interpreter that converts byte code to machine language code. As we know...
read more
One of the major features of java includes that why java is called platform independent language. Before understanding this feature we need to know about – Javac – compiler that converts source code to byte code. JVM- interpreter that converts byte code to machine language code. As we know java is both compiler & interpreter based language. Once the java code also known as source code is compiled, it gets converted to native code known as BYTE CODE which is portable & can be easily executed on all operating systems. Byte code generated is basically represented in hexa decimal format. This format is same on every platform be it Solaris work station or Macintosh, windows or Linux. After compilation, the interpreter reads the generated byte code & translates it according to the host machine. . Byte code is interpreted by Java Virtual Machine which is available with all the operating systems we install. so to port Java programs to a new platform all that is required is to port the interpreter and some of the library routines. Source code -> javac ->Universal byte code Universal byte ->jvm/java -> execute them on a particular machine. Another reason the makes Java a Platform independent language is the elimination of undefined or architecture dependent constructs. Therefore java is called platform independent language. read less
Comments

View 36 more Answers

Related Questions

I completed my graduation in 2017, now working as an HR Executive in a Consultancy. I want to move to IT Sector. Which course is best for me to learn and get success in life? Please Suggest me
Dear Kumar, My suggestion is to - become good in one programming language - preferably Java and one O/S preferably Linux. Be aware of Open Source systems. Try to identify the opportunities in your existing...
Kumar
What is the purpose of using throws keyword in java?
The throws statement is how you create an exception stack trace. There isn't much magic in java--it's not some underlying system mystery that creates an exception, it is simply a "Throw" statement, and...
Saritha
Should we learn DBMS and RDBMS without any Java training?
java or i can say any programming language is not required to learn DBMS or RDBMS
Karthik
0 0
6
What is selection sort in java?
Selection sort is a sorting algorithm. You can implement this algorithm in any language. The basic idea is to select the smallest element of the array and placing it to the head of array. This step needs...
Snehashis

Now ask question in any of the 1000+ Categories, and get Answers from Tutors and Trainers on UrbanPro.com

Ask a Question

Related Lessons

Class and Objects in Java
Class is a template or a blueprint which is used to describe an object. On other hand Object is a reference of a class which follows all the stuff written inside the class. How about taking the whole tour in the following video

Advance Java
1) Servlet • Basics of Servlet • Servlet Request • Servlet Collaboration • Servlet Config • Servlet Context • Attribute • Session Tracking • Event and Listener •...
A

Final modifier in Java
Can’t change value of variable if marked as final. It is best practice to mark method parameter as final if its value will not changes. Variable must be initialize either using Initializer block...

Facebook Analytics
Assume how the Facebook application will store the millions of customer's record in real-time: facebook = { 'jose': { 'name': 'jose', 'age': 33, 'hobby': , # cricket,football 'mobile': 1111111111, 'email':...

Palindrome Number : Java Function
An easier way to find out whether a number is a Palindrome number or not. Eg. 121, 88, 12321 etc public boolean isPalindrome ( int n ) { int rev = 0, r; for( i = n; i > 0; i /= 10 ) { r...

Recommended Articles

Before we start on the importance of learning JavaScript, let’s start with a short introduction on the topic. JavaScript is the most popular programming language in the world, precisely it is the language - for Computers, the Web, Servers, Smart Phone, Laptops, Mobiles, Tablets and more. And if you are a beginner or planning...

Read full article >

In the domain of Information Technology, there is always a lot to learn and implement. However, some technologies have a relatively higher demand than the rest of the others. So here are some popular IT courses for the present and upcoming future: Cloud Computing Cloud Computing is a computing technique which is used...

Read full article >

Java is the most famous programming language till date. 20 years is a big time for any programming language to survive and gain strength. Java has been proved to be one of the most reliable programming languages for networked computers. source:techcentral.com Java was developed to pertain over the Internet. Over...

Read full article >

Designed in a flexible and user-friendly demeanor, Java is the most commonly used programming language for the creation of web applications and platform. It allows developers to “write once, run anywhere” (WORA). It is general-purpose, a high-level programming language developed by Sun Microsystem. Initially known as an...

Read full article >

Looking for Java Training Classes?

Learn from the Best Tutors on UrbanPro

Are you a Tutor or Training Institute?

Join UrbanPro Today to find students near you
X

Looking for Java Training Classes?

The best tutors for Java Training Classes are on UrbanPro

  • Select the best Tutor
  • Book & Attend a Free Demo
  • Pay and start Learning

Learn Java Training with the Best Tutors

The best Tutors for Java Training Classes are on UrbanPro

This website uses cookies

We use cookies to improve user experience. Choose what cookies you allow us to use. You can read more about our Cookie Policy in our Privacy Policy

Accept All
Decline All

UrbanPro.com is India's largest network of most trusted tutors and institutes. Over 55 lakh students rely on UrbanPro.com, to fulfill their learning requirements across 1,000+ categories. Using UrbanPro.com, parents, and students can compare multiple Tutors and Institutes and choose the one that best suits their requirements. More than 7.5 lakh verified Tutors and Institutes are helping millions of students every day and growing their tutoring business on UrbanPro.com. Whether you are looking for a tutor to learn mathematics, a German language trainer to brush up your German language skills or an institute to upgrade your IT skills, we have got the best selection of Tutors and Training Institutes for you. Read more