Fortran vs Python - Newbie Question

Erik Johnson nobody at invalid.com
Tue Mar 27 14:11:01 EDT 2007


"Steven D'Aprano" <steve at REMOVE.THIS.cybersource.com.au> wrote in message
news:pan.2007.03.26.22.17.16.194451 at REMOVE.THIS.cybersource.com.au...

> Sheesh. Do Java developers go around telling everybody that Java is an
> interpreted language? I don't think so.
>
> What do you think the "c" in ".pyc" files stands for? "Cheese"?

On the contrary... Sun is very careful to make sure you understand that Java
is *COMPILED*!
Remember, remember, always remember: Java is COMPILED! See that: the java
"compiler": javac.  You have to call it explicitly when you build your Java
software so that it compiles Java source code (that way Java executes really
fast)!! (And don't forget, Java source is *compiled*, just like C++.)

What's a JVM? Why would you need one since Java is *compiled*, remember?

    But seriously... I'm not a language or architecture guru.  Is there any
real difference between a JVM and an interpreter? I mean, I have some
general feel that bytecode is a lower-level, more direct and more efficient
thing to be interpreting that Java or Python source, but at the bottom
level, you are still running an interpreter which is going to be
(significantly?) more inefficient than executing native machine instructions
directly on the CPU, right?

    Why is Python able to automatically compile source into bytecode on the
fly (when needed) but Java still forces you to do so explicitly?

    I don't mean to bash Java - I think it has it's place as well, but I
mean to note that Java is very carefully marketed whereas Python's image is
not managed by a major, international corporation.





More information about the Python-list mailing list