why java is platform independent?
Answers were Sorted based on User's Feedback
Answer / dinesh haridoss
Java was designed to not only be cross-platform in source
form like C, but also in compiled binary form. Since this
is frankly impossible across processor architectures Java
is compiled to an intermediate form called byte-code. A
Java program never really executes natively on the host
machine. Rather a special native program called the Java
interpreter reads the byte code and executes the
corresponding native machine instructions. Thus to port
Java programs to a new platform all that is needed is to
port the interpreter and some of the library routines. Even
the compiler is written in Java. The byte codes are
precisely defined, and remain the same on all platforms.
The second important part of making Java cross-platform is
the elimination of undefined or architecture dependent
constructs. Integers are always four bytes long, and
floating point variables follow the IEEE 754 standard for
computer arithmetic exactly. You don't have to worry that
the meaning of an integer is going to change if you move
from a Pentium to a PowerPC. In Java everything is
guaranteed.
| Is This Answer Correct ? | 4 Yes | 7 No |
Answer / asha
java have java virtual machine which make java plateform
independent..jvm convert input source code into bye code
which is run on any plateform..
| Is This Answer Correct ? | 9 Yes | 13 No |
Answer / suresh
java is platform independent because the virtual machine
include all operating system,so java is run on any platform
java compiler converted source code into byte code,then the
jvm to translate the byte code into machine code
| Is This Answer Correct ? | 3 Yes | 7 No |
main() { char *a = "Hello "; char *b = "World"; clrscr(); printf("%s", strcat(a,b)); } a. Hello b. Hello World c. HelloWorld d. None of the above
main() { int i=5,j=10; i=i&=j&&10; printf("%d %d",i,j); }
print numbers till we want without using loops or condition statements like specifically(for,do while, while swiches, if etc)!
enum colors {BLACK,BLUE,GREEN} main() { printf("%d..%d..%d",BLACK,BLUE,GREEN); return(1); }
main( ) { int a[2][3][2] = {{{2,4},{7,8},{3,4}},{{2,2},{2,3},{3,4}}}; printf(“%u %u %u %d \n”,a,*a,**a,***a); printf(“%u %u %u %d \n”,a+1,*a+1,**a+1,***a+1); }
main() { int i=300; char *ptr = &i; *++ptr=2; printf("%d",i); }
Write a program to receive an integer and find it's octal equivalent. How can i do with using while loop.
main() { int i = 3; for (;i++=0;) printf(“%d”,i); }
Write a program to model an exploding firecracker in the xy plane using a particle system
void main() { int i=5; printf("%d",i++ + ++i); }
respected sir, i did my MCA in 2013 when i am going to attend to an interview i was asked about my project how will i explain my project could please help me in this and my project title is "Social Networking Site For Social Responsibility"
How to swap two variables, without using third variable ?
104 Answers AB, ADP, BirlaSoft, Cisco, Cygnet Infotech, HCL, Hewitt, Honeywell, HP, IBM, Infosys, Manhattan, Microsoft, Mobius, Percept, Satyam, SofTMware, TCS, Wipro, Yamaha,