posted 13 years ago
A program in a scripting language, by definition, is stored in source-code form until you're ready to run it. When it runs, a program called an interpreter reads the source code and figures out what it means, generating machine code which can then be executed. Usually the translation is done one line at a time, as needed. That translation takes time, and so it slows the program down. For a compiled language, on the other hand, that translation is done by a compiler, once, before you install the program. Then when it is executed, it's already in machine-code form. It's faster because it doesn't have to be translated into machine code before running it.