Programming Language Comp Sci

download Programming Language Comp Sci

of 14

Transcript of Programming Language Comp Sci

  • 8/18/2019 Programming Language Comp Sci

    1/14

    Programming Languages

  • 8/18/2019 Programming Language Comp Sci

    2/14

    Programming Languages

    • Programming languages▫  Abbreviated forms of instructions that translate

    into machine language

    ▫ New programming languages make programmingeasier for people who are not necessarily hardware

    experts

  • 8/18/2019 Programming Language Comp Sci

    3/14

    Programming Languages

    Figure 5.1

    The evolution of

    programming

    languages

  • 8/18/2019 Programming Language Comp Sci

    4/14

    Programming Languages

    • Machine Languages ML!▫ "nly languages computers can directly interpret to

    carry out instructions▫ #tring of $%s& and $'s& for a machine languageinstruction

    ▫ ML coding( time)consuming and error)prone

    ▫ ML programmers( concerned with hardware details▫ *very computer or family of computers has its own

    ML+ each is machine)dependent,

  • 8/18/2019 Programming Language Comp Sci

    5/14

    Programming Languages

    • Assembly Languages

    ▫ More *nglish)like+ codes shorter than machinelanguages

    ▫  Assembler translates into machine language

    ▫  Advantages of machine or assembly languages

    Programmer in control of hardware Programs written in low)level languages run more

    efficiently,

  • 8/18/2019 Programming Language Comp Sci

    6/14

    Programming Languages

    Figure 5.2 The instruction “ADD 2 and 5 and assign the result to variable

    y” ritten in different programming languages

  • 8/18/2019 Programming Language Comp Sci

    7/14

    Programming Languages

    • Procedural Languages

    ▫ -hird)generation procedural! languages are more*nglish)like than assembly languages,

    ▫ Programmers focus on the procedure of theapplication problem at hand,

    ▫ #ome languages are standardi.ed or portable,▫ /elatively easy to learn0 write0 and debug,

    ▫ 1"/-/AN0 2"3"L0 3A#42

    ▫ /e5uires compiling and linking to test

  • 8/18/2019 Programming Language Comp Sci

    8/14

    Programming Languages

    • 1ourth 6eneration Languages 76L!

    ▫ 76Ls are more *nglish)like than procedurallanguages,

    ▫ Programmer only has to select an action withouthaving to specify the action&s formula or

    procedure,▫ *asy to learn and use+ shorter application

    development time,

    ▫ Power3uilder0 1"28#0 N"MA90 and /AM4#

  • 8/18/2019 Programming Language Comp Sci

    9/14

    Programming Languages

    • :isual Programming▫ Languages that let programmers create field

     windows0 scroll)down menus0 click buttons0 etc,0

     by choosing from a palette▫  Appropriate code written automatically 

    ▫ 4ntegrated programming environment

    ▫  Accelerates work 

    ▫ Microsoft&s :isual 3asic

  • 8/18/2019 Programming Language Comp Sci

    10/14

    Programming Languages

    • "b;ect)"riented Programming ""P!

    ▫ *mphasis on the ob;ects involved in the task0 noton the procedure,

    ▫  An ob;ect encapsulates a data set with the codethat is used to operate on it,

    ▫ #tandardi.ed programming modules can bereused,

    ▫  Applications can be rapidly developed withappropriate ob;ects from an ob;ect library,

  • 8/18/2019 Programming Language Comp Sci

    11/14

    Programming Languages

    Figure 5.! Advantages of ob"ect#oriented programming $%%&' over procedural

    languages

  • 8/18/2019 Programming Language Comp Sci

    12/14

    Programming Languages

    Figure 5.(  The ob"ect )*&+%,))

  • 8/18/2019 Programming Language Comp Sci

    13/14

    Programming Languages

    Figure 5.5 Advantages and disadvantages of higher#level

    programming languages

  • 8/18/2019 Programming Language Comp Sci

    14/14

    Programming Languages Application #oftware vs, #ystem

    #oftware Application( a program developed to

    address a specific business need+ softwarefor development of such programs,

    #ystem( programs designed to carry outgeneral routine operations0 such asloading0 copying0 or deleting a file,