Computer Programs and Programming Languages - PowerPoint PPT Presentation

About This Presentation
Title:

Computer Programs and Programming Languages

Description:

Computer Programs and Programming Languages What is a computer program? Set of instructions that directs computer to perform tasks Programming language used to ... – PowerPoint PPT presentation

Number of Views:584
Avg rating:3.0/5.0
Slides: 49
Provided by: steve1729
Category:

less

Transcript and Presenter's Notes

Title: Computer Programs and Programming Languages


1
Computer Programs and Programming Languages
  • What is a computer program?
  • Set of instructions that directs computer to
    perform tasks
  • Programming languageused to write instructions

2
Computer Programs and Programming Languages
  • What are low-level languages and high-level
    languages?

High-level language
Low-levellanguage
Machine-dependentruns only on one type of
computer
Often machine-independentcan run on many
different types of computers
Machine and assembly languages are low-level
3
Low-Level Languages
  • What is machine language?
  • Only language computer directly recognizes

4
Low-Level Languages
  • What is assembly language?
  • Instructions made up of symbolic instruction
    codes, meaningful abbreviations and codes
  • Source program contains code to be converted to
    machine language

5
Procedural Languages
  • What is a procedural language?

Uses series of English-like words to write
instructions
Programmer writes instructions that tell computer
what to accomplish and how to do it
Most widely used are BASIC, COBOL, and C
Often called third-generation language (3GL)
6
Procedural Languages
  • What is a compiler?
  • Program that converts entire source program into
    machine language before executing it

7
Procedural Languages
  • What is an interpreter?
  • Program that translates and executes one program
    code statement at a time
  • Does not produce object program

8
Procedural Languages
  • What is BASIC?
  • Designed for use as simple, interactive
    problem-solving language
  • Beginners All-purpose Symbolic Instruction Code

9
Procedural Languages
  • What is COBOL?
  • Designed for business applications
  • English-like statements make code easy to read,
    write, and maintain
  • COmmon Business-Oriented Language

10
Procedural Languages
  • What is C?
  • Powerful language originally designed to write
    system software
  • Requires professional programming skills

11
Object-Oriented Programming Languages
  • What is an object-oriented programming (OOP)
    language?

Used to implement object-oriented design
Major benefit is ability to reuse existing
objects
  • Event-drivenchecks for and responds to set of
    events

C and Java are complete object-oriented
languages
Object is item that contains data and
procedures that act on data
Event is action to which program responds
12
Object-Oriented Programming Languages
  • What is C?
  • Includes all elements of C, plus additional
    features for working with object-oriented
    concepts
  • Used to develop database and Web applications

13
Object-Oriented Programming Languages
  • What is Java?
  • Developed by Sun Microsystems
  • Similar to C but uses just-in-time (JIT)
    compiler to convert source code into machine code

14
Object-Oriented Programming Languages
  • What is a visual programming language?

Provides visual or graphical interface for
creating source code
Sometimes calledfifth-generation language
Often used in RAD (rapid application development)
environment
15
Object-Oriented Programming Languages
  • What is Visual Studio 2005?
  • Suite of visual programming languages and RAD
    tools
  • .NET is set of technologies that allows program
    to run on Internet
  • Visual Basic 2005 is used to build complex
    object-based programs

16
Object-Oriented Programming Languages
  • What is Delphi?
  • Powerful visual programming tool
  • Ideal for large-scale enterprise and Web
    applications

17
Object-Oriented Programming Languages
  • What is PowerBuilder?
  • Another powerful visual programming tool
  • Best suited for Web-based and large-scale
    object-oriented applications

18
Nonprocedural Languages and Program Development
Tools
  • What are nonprocedural languages and program
    development tools?

Nonprocedural LanguageThe programmer writes
English-like instructions or interacts with a
visual environment to retrieve data from files or
a database
Program Development ToolsUser-friendly programs
designed to assist both programmers and users in
creating programs
19
Nonprocedural Languages and Program Development
Tools
  • What is RPG (Report Program Generator)?
  • Nonprocedural language used for generating
    reports, performing computations, and updating
    files

20
Nonprocedural Languages and Program Development
Tools
  • What is a fourth-generation language (4GL)?
  • Nonprocedural language that allows access to data
    in database
  • Popular 4GL is SQL, query language that allows
    users to manage data in relational DBMS

21
Nonprocedural Languages and Program Development
Tools
  • What is an application generator?
  • Program that creates source code or machine code
    from specification
  • Consists of report writer, form, and menu
    generator
  • Form provides areas for entering data

22
Nonprocedural Languages and Program Development
Tools
  • What is Visual Basic for Applications (VBA)?
  • Macro programming language
  • Macroseries of statements used to automate tasks

23
Web Page Development
  • What is HTML (Hypertext Markup Language)?
  • Used to create Web pages

24
Web Page Development
  • How are special effects and interactive elements
    added to a Web page?

25
Web Page Development
  • What is the common gateway interface (CGI)?
  • Communications standard that defines how Web
    server communicates with outside sources
  • CGI scriptprogram that manages sending and
    receiving across CGI

Step 3. When the user submits a request, it is
sent to the CGI program. The CGI program contacts
the database and requests information for the
user. In this case, it looks for a movie titled
The Wizard of Oz.
26
Web Page Development
  • What is a scripting language?
  • Typically easy to learn and use
  • JavaScriptadds dynamic content and interactive
    elements to Web page
  • VBScript (Visual Basic, Scripting Edition)adds
    intelligence and interactivity to Web page
  • Perl (Practical Extraction and Report
    Language)has powerful text processing
    capabilities

27
Web Page Development
  • What is dynamic HTML (DHTML)?
  • Allows developers to include more graphical
    interest and interactivity in Web page

28
Web Page Development
  • What are XHTML, XML, and WML?

Includes features of HTML and XML
XHTML (Extensible HTML)enables Web sites to be
displayed more easily on microbrowsers
XML (Extensible Markup Language)allows
developers to create customized tags
Server sends entire record to client, enabling
client to do much of processing without going
back to server
WML (Wireless Markup Language)allows developers
to design pages specifically for microbrowsers
Uses wireless application protocol (WAP),
standard that specifies how wireless devices
communicate with Web
29
Web Page Development
  • What is Web page authoring software?
  • Creates sophisticated Web pages without using
    HTML
  • Generates HTML

30
Multimedia Program Development
  • What is multimedia authoring software?
  • Combines text, graphics, animation, audio, and
    video into interactive presentation
  • Used for computer-based training (CBT) and
    Web-based training (WBT)
  • Software includes Toolbook, Authorware, and
    Director

31
Other Programming Languages
  • What are other available programming languages?

ALGOL
ADA
APL
FORTH
LISP
HYPERTALK
FORTRAN
LOGO
PASCAL
MODULA-2
PILOT
SMALLTALK
PROLOG
PL/I
32
The Program Development Cycle
  • What is the program development cycle?
  • Steps programmers use to build computer programs
  • Programming teamGroup of programmers working on
    program

33
Step 1 Analyze Requirements
  • What is involved in analyzing the requirements?
  1. Review requirements
  2. Meet with systems analyst and users
  3. Identify input, output, processing, and data
    components
  • IPO chartIdentifies programs inputs, outputs,
    and processing steps

34
Step 2 Design Solution
  • What is involved in designing the solution?

Two approaches
Devise solution algorithm, step-by-step procedure
to solve problem
35
Step 2 Design Solution
  • What is a hierarchy chart?
  • Shows program modules graphically
  • Also called structure chart

36
Step 2 Design Solution
  • What is object-oriented (OO) design?
  • Programmer packages data and procedure into
    single unit, an object
  • Objects are grouped into classes
  • Class diagram represents hierarchical
    relationships of classes graphically

37
Step 2 Design Solution
  • What is a sequence control structure?
  • Control structure that shows actions following
    each other in order
  • Control structure depicts logical order of
    program instructions

38
Step 2 Design Solution
  • What is a selection control structure?
  • Tells program which action to take, based on a
    certain condition
  • Two types
  • Case control structure
  • If-then-else control structureyields one of two
    possibilities true or false

39
Step 2 Design Solution
  • What is a case control structure?
  • Yields one of three or more possibilities

40
Step 2 Design Solution
  • What is a repetition control structure?
  • Enables program to perform one or more actions
    repeatedly
  • Do-while control structurerepeats as long as
    condition is true
  • Do-until control structurerepeats until
    condition is true

41
Step 2 Design Solution
  • What is a program flowchart?
  • Graphically shows logic in solution algorithm

42
Step 2 Design Solution
  • What is an example of a flowchart?

43
Step 2 Design Solution
  • What is flowcharting software?
  • Used by programmers to develop flowcharts

44
Step 2 Design Solution
  • What is pseudocode?
  • Uses condensed form of English to convey program
    logic

45
Step 3 Validate Design
Check program design for accuracy
Programmer checks logic for correctness and
attempts to uncover logic errors
  • What is involved in validating the design?

Desk checkprogrammers use test data to step
through logic
Logic errordesign flaw that causes inaccurate
results
Structured walkthroughprogrammer explains logic
of algorithm while programming team steps through
program logic
Test datasample data that mimics real data that
program will process
46
Step 4 Implement Design
  • What is implementation?
  • Writing the code that translates the design into
    a program
  • Syntaxrules that specify how to write
    instructions
  • Commentsprogram documentation
  • Extreme programming (XP)coding and testing as
    soon as requirements are defined

47
Step 5 Test Solution
  • What is involved in testing the solution?

Ensure program runs correctly and is error free
Debugginglocating and correcting syntax and
logic errors, or bugs
Test copy of program, called beta, sometimes used
to find bugs
48
Step 6 Document Solution
  • What is involved in documenting the solution?
  • Programmer performs two activities

Reviews program coderemoves dead code, program
instructions that program never executes
Reviews documentation
Write a Comment
User Comments (0)
About PowerShow.com