The concept taught in the class, is it the same in Java

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

The concept taught in the class, is it the same in Java

ajksdf
After 12 weeks, I have gained a lot of knowledge from the course.

I wonder if those concepts I learnt is transferrable when I am learning Java. Eg. the 8 VM segments in the memory, the mechanism of handling local variables, call function and return address in the low level.

Any opinions?
Reply | Threaded
Open this post in threaded view
|

Re: The concept taught in the class, is it the same in Java

WBahn
Administrator
There are a lot of conceptual similarities, but every programming language is different.

The Java Virtual Machine is going to be structured very differently -- it's a LOT more complex, for one thing -- but the high-level concept is the same in that the Java program is compiled to an intermediate level language (Java Byte Code, in this case) that is run on a virtual machine (the JVM) that translates the byte code into code sequences that can actually be run on the device.

Understanding how function calls and stack frames work will be very useful in helping you understand what your program is doing -- and why it isn't working -- even though the details of how the calls and stack frames work are going to vary from language to language and operating system to operating system. But at the level of a high-level language, the basic concepts are what is important.

Having an idea of what has to go on underneath the hood in order to print out a number or get a number from the user will give you a much better appreciation for what is involved and also some of the subtle distinctions that escape many programs, such as the difference between storing the value 42 and the string "42".