2. Objectives Overview
Differentiate between
machine and assembly
languages
Identify and discuss the
purpose of procedural
programming languages,
and describe the features of
C and COBOL
Identify and discuss the
characteristics of these
object-oriented
programming languages
and program development
tools
Identify the uses of other
programming languages
and program development
tools
Describe various ways to
develop Web pages
Discovering Computers 2012: Chapter 13 2See Page 663
for Detailed Objectives
3. Objectives Overview
Identify the uses of
popular multimedia
authoring programs
List the six steps in the
program development
life cycle
Differentiate between
structured design and
object-oriented design
Explain the basic
control structures and
design tools used in
designing solutions to
programming problems
Discovering Computers 2012: Chapter 13 3See Page 663
for Detailed Objectives
4. Computer Programs
and Programming Languages
• A computer program is a series of instructions
that directs a computer to perform tasks
– Created by a programmer using a programming
language
Discovering Computers 2012: Chapter 13 4Pages 664 – 665
Figure 13-1
5. Low-Level Languages
• Machine language is
the first generation of
programming languages
• Only language the
computer directly
recognizes
Discovering Computers 2012: Chapter 13 5Page 665
Figure 13-2
6. Low-Level Languages
• Assembly language is the
second generation of
programming languages
• Programmer writes
instructions using
symbolic instruction
codes
• A source program
contains the code to be
converted to machine
language
Discovering Computers 2012: Chapter 13 6Pages 665 – 666
Figure 13-3
7. High Level Languages
– Close to human languages
– Easy to understand
– Making the process of developing a program simpler
and more understandable relative to a lower-level
language
– These 3rd Generation Languages
– C, C++, C#, Java, .Net are examples of High Level
Languages
Discovering Computers 2012: Chapter 13 7Web
8. Programming Languages
• Compiler
– A compiler is a computer program (or set of programs)
that transforms source code written in a programming
language (the source language) into another computer
language (the target language, often having a binary
form known as object code). The most common
reason for converting a source code is to create
an executable program.
Discovering Computers 2012: Chapter 13 8Web
10. Programming Languages
• Interpreter
– In computer science, an interpreter is a computer
program that directly executes, i.e. performs,
instructions written in a programming or scripting
language, without previously compiling them into a
machine language program.
Discovering Computers 2012: Chapter 13 10
12. Programming Languages
• Assembler
– An assembler is a program that takes basic
computer instructions and converts them into a
pattern of bits that the computer's processor can use
to perform its basic operations. Some people call
these instructions assembler language and others use
the term assembly language.
Discovering Computers 2012: Chapter 13 12
15. Procedural Languages
• In a procedural language, the programmer writes
instructions that tell the computer what to
accomplish and how to do it
– Third-generation language (3GL)
Discovering Computers 2012: Chapter 13 15Pages 666 - 667
A compiler
translates an entire
program before
executing it
An interpreter converts
and executes one code
statement at a time
16. Object-Oriented Programming Languages
and Program Development Tools
• An object-oriented programming (OOP) language allows
programmers the ability to reuse and modify existing
objects
• Other advantages include:
Discovering Computers 2012: Chapter 13 16Page 669
Objects can be
reused
Programmers
create applications
faster
Work well in a
RAD environment
Most program
development tools
are IDEs
17. Object-Oriented Programming Languages
and Program Development Tools
A visual programming language is a language that
uses a visual or graphical interface for creating all
source code
Borland’s Delphi is a powerful program
development tool that is ideal for building large-
scale enterprise and Web applications in a RAD
environment
Discovering Computers 2012: Chapter 13 17Page 673
18. Algorithm
• In mathematics and computer science,
an algorithm is a step-by-step procedure for
calculations. Algorithms are used for calculation,
data processing, and automated reasoning.
Discovering Computers 2012: Chapter 13 18
19. Heuristic
• A heuristic is a technique designed for solving a
problem more quickly when classic methods are
too slow, or for finding an approximate solution
when classic methods fail to find any exact
solution. This is achieved by trading optimality,
completeness, accuracy, or precision for speed. In
a way, it can be considered a shortcut.
Discovering Computers 2012: Chapter 13 19Web
20. Algorithm Vs. Heuristic
• An algorithm is a set of well-defined instructions for carrying
out a particular task. It must be sound and complete. That mean
it must gives you the correct answer and it must works for all
cases. Usually, an algorithm is predictable, deterministic, and
not subject to chance. An algorithm tells you how to go from
point A to point B with no detours, no side trips to points D, E,
and F, and no stopping to smell the roses or have a cup of joe.
• A heuristic is a technique that helps you look for an answer. Its
results are subject to chance because a heuristic tells you only
how to look, not what to find. It doesn’t tell you how to get
directly from point A to point B; it might not even know where
point A and point B are. In effect, a heuristic is an algorithm in a
clown suit. It’s less predictable, it’s more fun, and it comes
without a 30-day, money-back guarantee.
Discovering Computers 2012: Chapter 13 20Web
21. Other Programming Languages
and Development Tools
• A 4GL (fourth-generation language) is a
nonprocedural language that enables users and
programmers to access data in a database
– One popular 4GL is SQL
Discovering Computers 2012: Chapter 13 21Page 674
Figure 13-13
22. Other Programming Languages
and Development Tools
• Classic programming languages include:
Discovering Computers 2012: Chapter 13 22Page 675
Figure 13-14
Ada ALGOL APL BASIC
Forth FORTRAN HyperTalk LISP
Logo Modula-2 Pascal PILOT
PL/1 Prolog RPG Smalltalk
23. Other Programming Languages
and Development Tools
• An application generator is a program that creates
source code or machine code from a specification of the
required functionality
– Often bundled as part of a DBMS
Discovering Computers 2012: Chapter 13 23Page 676
Figure 13-15
24. Web Page Development
• Web browsers can execute short programs to add
interactive elements to Web pages
• To send and receive information between your computer
and a Web server, these programs use the CGI (common
gateway interface)
Discovering Computers 2012: Chapter 13 24Page 680
Scripts Applets
Servlets
ActiveX
controls
25. Summary
Various programming
languages used to
create computer
programs
A variety of Web
development and
multimedia
development tools
Steps in the program
development life cycle
and tools used to make
this process efficient
Discovering Computers 2012: Chapter 13 25Page 697