What's the difference between a script and a program?

Discussion in 'Website Development & Design' started by Fergal, Aug 9, 2011.

  1. Fergal

    Fergal
    uix_expand uix_collapse
    Premium Member
    Premium Member

    Joined:
    Nov 18, 2007
    Messages:
    10,575
    Likes Received:
    1,165
    As I've mentioned before, I've been learning some PHP recently. My PHP book describes PHP as a scripting language as opposed to a programming language. So my question is what's the difference between a script and a program?

    Thanks!
     
    • Like Like x 1
  2. Matt

    Matt
    uix_expand uix_collapse
    Member

    Joined:
    Feb 15, 2011
    Messages:
    299
    Likes Received:
    15
    I didn't know what the difference was before you asked the question, but it is something I should know. After a quick search, this is what I found out. It is from Wikipedia.

    A programming language is an artificial language designed to communicate instructions to a machine, particularly a computer. Programming languages can be used to create programs that control the behavior of a machine and/or to express algorithms precisely.

    A scripting language, script language or extension language is a programming language that allows control of one or more applications. "Scripts" are distinct from the core code of the application, as they are usually written in a different language and are often created or at least modified by the end-user. Scripts are often interpreted from source code or bytecode, whereas the application is typically first compiled to native machine code.
     
    • Like Like x 2
  3. daytrader

    daytrader
    uix_expand uix_collapse
    Active Member

    Joined:
    Jul 29, 2009
    Messages:
    1,678
    Likes Received:
    216
    i'm not that knowledgable about this though. Scripts as i know are files that you know exactly it would do.
    Programs however are organized scripts that will do things dynamically according to what the user will command.
     
  4. Bliss Elliosn

    Bliss Elliosn
    uix_expand uix_collapse
    Member

    Joined:
    Apr 28, 2011
    Messages:
    154
    Likes Received:
    28
    Fergal, Matt has described very well. Moreover, I would like to add that PHP is a server side scripting language to write programs.
    Plus, scripts written in scripting language are the part or subset of the main program, means scripts are embedded in the HTML to add a functionality to a web page like different menu styles or graphic displays or to serve dynamic advertisements. These features are processed on the server side but the scripts on a specific page run on a client side.

    I hope I have also helped you.
     
  5. Gary Barzel

    Gary Barzel
    uix_expand uix_collapse
    Member

    Joined:
    Jan 10, 2011
    Messages:
    135
    Likes Received:
    48
    I think in short, the main difference is that a script is interpreted, while a program is executed.
     
  6. Fergal

    Fergal
    uix_expand uix_collapse
    Premium Member
    Premium Member

    Joined:
    Nov 18, 2007
    Messages:
    10,575
    Likes Received:
    1,165
    Thanks everyone for the helpful replies, I understand it much better now.
     
  7. Ken Peterson

    Ken Peterson
    uix_expand uix_collapse
    Member

    Joined:
    Jun 20, 2011
    Messages:
    213
    Likes Received:
    7
    Hi,
    To create an application like Excel you need programming language. But to write macros you need scripting like VBA. To put in simple words, you can customize an application with scripting without the hassle of buying the complete compiler and IDE etc. A mini compiler is already integrated with the application.
     
  8. MariahLinda99

    MariahLinda99
    uix_expand uix_collapse
    Member

    Joined:
    Jul 28, 2011
    Messages:
    30
    Likes Received:
    0
    Script are the short statement and the combination of these strips are known as the program.
     
  9. alexa007

    alexa007
    uix_expand uix_collapse
    New Member

    Joined:
    Aug 11, 2011
    Messages:
    16
    Likes Received:
    0
    There are many differences in script and a program.
    1. A script is written in a scripting language and a program is written in a programming language.
    2. Scripts are distinct from the core code of the application, which is usually written in a different language, it created by the end-user in other side the program has an executable form that the computer can use directly to execute the instructions.
    3. Scripts are often interpreted from source code, whereas the applications they control are traditionally compiled to native machine code. The same program in its human-readable source code form, from which executable programs are derived.
     
  10. anusha

    anusha
    uix_expand uix_collapse
    New Member

    Joined:
    Sep 27, 2011
    Messages:
    9
    Likes Received:
    0
    Script is in our common language it can be understand by anyone..with out any knowledge we understood..But program is in programming language it can understood by only experts..and we have some knowledge about that..we have to follow some rules in programming..In script no need to follow any rules..
     
  11. girdharkumar

    girdharkumar
    uix_expand uix_collapse
    Member

    Joined:
    Dec 27, 2011
    Messages:
    54
    Likes Received:
    0
    hi

    we use script in programming language but it is not programming
     
  12. girdharkumar

    girdharkumar
    uix_expand uix_collapse
    Member

    Joined:
    Dec 27, 2011
    Messages:
    54
    Likes Received:
    0
    script run on server but programme not
     
  13. localseoguru

    localseoguru
    uix_expand uix_collapse
    New Member

    Joined:
    Jan 6, 2012
    Messages:
    2
    Likes Received:
    0
    HI,I think the main difference is that a script is interpreted, while a program is executed

    Local Seo
     

Share This Page