Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What's the difference between a "script" and an "application"?

Tags:

terminology

I'm referring to distinctions such as in this answer:

...bash isn't for writing applications it's for, well, scripting. So sure, your application might have some housekeeping scripts but don't go writing critical-business-logic.sh because another language is probably better for stuff like that.

As programmer who's worked in many languages, this seems to be C, Java and other compiled language snobbery. I'm not looking for reenforcement of my opinion or hand-wavy answers. Rather, I genuinely want to know what technical differences are being referred to.

(And I use C in my day job, so I'm not just being defensive.)

like image 746
Jon Ericson Avatar asked Sep 19 '08 00:09

Jon Ericson


People also ask

How is scripting different from applications?

The theoretical difference between the two is that scripting languages do not require the compilation step and are rather interpreted. For example, normally, a C program needs to be compiled before running whereas normally, a scripting language like JavaScript or PHP need not be compiled.

What is script in application?

Application scripting allows users to control an application's behavior by writing scripts. For example, users might write scripts to automate routine tasks. They might use scripts to add new features or to customize existing functionalities.

What's the difference between scripts and programs?

A "program" in general, is a sequence of instructions written so that a computer can perform certain task. A "script" is code written in a scripting language. A scripting language is nothing but a type of programming language in which we can write code to control another software application.

What is the difference between a python script and program?

Generally, all the scripting languages are considered programming languages. The main difference between both is scripting languages don't require any compilation and are directly interpreted. The compiled codes execute faster than the interpreted codes as they are changed in to a native machine program.


2 Answers

Traditionally a program is compiled and a script is interpreted, but that is not really important anymore. You can generate a compiled version of most scripts if you really want to, and other 'compiled' languages like Java are in fact interpreted (at the byte code level.)

A more modern definition might be that a program is intended to be used by a customer (perhaps an internal one) and thus should include documentation and support, while a script is primarily intended for the use of the author.

The web is an interesting counter example. We all enjoy looking things up with the Google search engine. The bulk of the code that goes into creating the 'database' it references is used only by its authors and maintainers. Does that make it a script?

like image 172
Jeff Avatar answered Oct 03 '22 22:10

Jeff


I would say that an application tends to be used interactively, where a script would run its course, suitable for batch work. I don't think it's a concrete distinction.

like image 24
Bernard Avatar answered Oct 03 '22 23:10

Bernard