Programming Languages

Slides:



Advertisements
Similar presentations
PROBLEM SOLVING TECHNIQUES
Advertisements

CHAPTER 2 GC101 Program’s algorithm 1. COMMUNICATING WITH A COMPUTER  Programming languages bridge the gap between human thought processes and computer.
Chapter 2- Visual Basic Schneider1 Chapter 2 Problem Solving.
Algorithms and flow charts
CS105 INTRODUCTION TO COMPUTER CONCEPTS INTRO TO PROGRAMMING Instructor: Cuong (Charlie) Pham.
Program Flow Charting How to tackle the beginning stage a program design.
Program Flow Charting How to tackle the beginning stage a program design.
Chapter 16 Programming and Languages: Telling the Computer What to Do.
CS 104 Introduction to Computer Science and Graphics Problems Software and Programming Language (2) Programming Languages 09/26/2008 Yang Song (Prepared.
Chapter 2- Visual Basic Schneider1 Chapter 2 Problem Solving.
Chapter 1: Introduction To Computer | SCP1103 Programming Technique C | Jumail, FSKSM, UTM, 2005 | Last Updated: July 2005 Slide 1 Introduction To Computers.
Introduction to Programming Lecture Number:. What is Programming Programming is to instruct the computer on what it has to do in a language that the computer.
สาขาวิชาเทคโนโลยี สารสนเทศ คณะเทคโนโลยีสารสนเทศ และการสื่อสาร.
CSC141 Introduction to Computer Programming
PROGRAMMING LANGUAGES Prof. Lani Cantonjos. PROGRAM - set of step-by-step instructions that tells or directs the computer what to do. PROGRAMMING LANGUAGE.
Programming Lifecycle
TMF1013 : Introduction To Computing Lecture 1 : Fundamental of Computer ComputerFoudamentals.
Software Life Cycle What Requirements Gathering, Problem definition
Problem Solving Techniques. Compiler n Is a computer program whose purpose is to take a description of a desired program coded in a programming language.
C++ Programming Language Lecture 2 Problem Analysis and Solution Representation By Ghada Al-Mashaqbeh The Hashemite University Computer Engineering Department.
IXA 1234 : C++ PROGRAMMING CHAPTER 1. PROGRAMMING LANGUAGE Programming language is a computer program that can solve certain problem / task Keyword: Computer.
INTRODUCTION TO COMPUTING CHAPTER NO. 04. Programming Languages Program Algorithms and Pseudo Code Properties and Advantages of Algorithms Flowchart (Symbols.
Chapter 1 Introduction Chapter 1 Introduction 1 st Semester 2015 CSC 1101 Computer Programming-1.
Introduction to Computer Application (IC) MH Room 517 Time : 7:00-9:30pm.
1 Program Planning and Design Important stages before actual program is written.
`. Lecture Overview Structure Programming Basic Control of Structure Programming Selection Logical Operations Iteration Flowchart.
CS2301:Computer Programming 2
How to Program? -- Part 1 Part 1: Problem Solving –Analyze a problem –Decide what steps need to be taken to solve it. –Take into consideration any special.
How Are Computers Programmed? CPS120: Introduction to Computer Science Lecture 5.
LESSON 1 Introduction to Programming Language. Computer  Comprised of various devices that are referred to as HARDWARE.  The computer programs that.
ALGORITHMS AND FLOWCHARTS. Why Algorithm is needed? 2 Computer Program ? Set of instructions to perform some specific task Is Program itself a Software.
Lecture #1: Introduction to Algorithms and Problem Solving Dr. Hmood Al-Dossari King Saud University Department of Computer Science 6 February 2012.
Software. Introduction n A computer can’t do anything without a program of instructions. n A program is a set of instructions a computer carries out.
Chapter 2- Visual Basic Schneider1 Chapter 2 Problem Solving.
Lecture 3 Computer Programming -1-. The main steps of program development to solve the problem: 1- problem definition : The problem must be defined into.
Introduction to Computer Programming Concepts M. Uyguroğlu R. Uyguroğlu.
 Problem Analysis  Coding  Debugging  Testing.
CIS 365: Visual Application Development Introduction to Computers and Programming.
CHAPTER 2 GC101 Program’s algorithm 1. COMMUNICATING WITH A COMPUTER  Programming languages bridge the gap between human thought processes and computer.
Chapter 1 Introduction 2nd Semester H
GC101 Introduction to computers and programs
Topic: Programming Languages and their Evolution + Intro to Scratch
Number System.
Introduction to programming
CSCI-235 Micro-Computer Applications
Computer Programming.
Chapter 2- Visual Basic Schneider
ALGORITHMS AND FLOWCHARTS
Lecture 2 Introduction to Programming
Application Development Theory
Programming Logic n Techniques
Chapter 4 Computer Software.
Unit# 9: Computer Program Development
Chapter 2- Visual Basic Schneider
King Saud University College Of Applied Studies and Community Services CSC 1101 Computer Programming-1 Done By: Asmal Alosaimi Edited By: Fatimah Alakeel.
Chapter 1 Introduction(1.1)
CS105 Introduction to Computer Concepts Intro to programming
Chapter 2- Visual Basic Schneider
Chapter One: An Introduction to Programming and Visual Basic
King Saud University College Of Applied Studies and Community Services CSC 1101 Computer Programming-1 Done By: Asmal Alosaimi Edited By: Fatimah Alakeel.
A programming language
PROGRAMMING FUNDAMENTALS Lecture # 03. Programming Language A Programming language used to write computer programs. Its mean of communication between.
Flowcharts and Pseudo Code
Lecture 8 Programming Paradigm & Languages. Programming Languages The process of telling the computer what to do Also known as coding.
ICT Gaming Lesson 2.
Introduction to Programming
Tonga Institute of Higher Education IT 141: Information Systems
Tonga Institute of Higher Education IT 141: Information Systems
CS105 Introduction to Computer Concepts Intro to programming
WRITING AN ALGORITHM, PSEUDOCODE, AND FLOWCHART LESSON 2.
Presentation transcript:

Programming Languages

Introduction The computer programming involves designing the computer programs to solve different kinds of problems as well as to control different operations of the computer A computer is nothing without a computer program A computer program is designed after understanding the problem To develop a correct program, the programmer must write program instructions in the proper sequence

Example To find out the average marks of the student Get the marks of all subjects of the student Calculate the total marks Calculate the average marks Print the average marks

Algorithm The step-by-step procedure for the solution of the problem is called algorithm The algorithm represent the sequence of steps or instructions and the order in which these steps are taken for the solution of the problem An algorithm provides the procedure for the solution of the problem in general terms only An algorithm is written before writing the actual computer program It is written by using short English statements

Example Program to find average and sum of three numbers INPUT “Enter the first number: ” ; X INPUT “Enter the second number: ” ; Y INPUT “Enter the third number: ” ; Z LET SUM = X + Y + Z AVG = SUM/3 PRINT “Sum of three numbers is: ” ; SUM PRINT “Average of three numbers is: ” ; AVG END http://rajastutorials.com/program-find-average-and-sum-of-three-numbers-gw-basic/

Altering Order of Algorithm Algorithm operations are ordered in that there is first instruction, a second instruction etc An algorithm must have the ability to alter the order of its instructions An instruction that alters the order of an algorithm is called a control structure

Types of Control Structures Sequential Structure Conditional Structure Iterative Structure

Example http://www.slideshare.net/sajibbgc/algorithms-and-flowcharts-27859039

Pseudo code Pseudo code is a problem solving tool It is a generic way of describing an algorithm without use of any specific programming language syntax Statements in pseudo code represent the logic of actual computer program in natural language Cannot be compiled nor executed Also called program design language

Example If student’s marks is greater than or equal to 50% Else Print “Passed” Else Print “Failed”

Flow Chart Graphical or symbolic representation of the solution of a problem Graphical representation of algorithm or pseudo code Used to describe the solution of the problem Easy to understand Plan to be followed for coding a program Errors in the logic of the program can be detected very easily in flowchart

Symbols of Flow Chart Each step in solving the problem is represented by a different symbol Each symbol also contains a short description about the step The flow chart symbols are linked together with arrows that show the direction of flow of data or control

Operating System Functions http://www.smartdraw.com/flowchart/flowchart-symbols.htm

Example http://www.slideshare.net/MELJUN2009/flowchart-lecture-16088527

Example http://www.slideshare.net/MELJUN2009/flowchart-lecture-16088527

Example http://cquestionsandanswers.blogspot.com/p/flow-charts.html

Programming Languages A language is defined as a way of communication between two persons Programming language is a means of communication between computer and the user A computer program is written or prepared in programming language Each programming language has a set of alphabets and rules for writing computer programs

Types of Programming Languages Low Level Language Machine Language Assembly Language High Level Language FORTRAN COBOL C++

Types of High Level Language Procedural language Non-Procedural language Object Oriented Programming languages

Advantages of High Level Languages Easy to learn Easy to understand Easy to write program Easy to detect and remove errors Built in library functions Machine independence

Difference between Low Level & High Level Languages Low Level Languages is close to machine language, while High level languages is close to human language Low Level Languages is machine dependent, while High level languages is machine independent

Programming Techniques Structured Programming Object Oriented Programming Event Driven Programming Visual Programming

Language Processors A computer understands instructions in machine code A program written in any high level programming language is called the source program The source code cannot be executed directly by the computer The source program must be converted into machine code before running it on the computer “The special translator system software that is used to translate the program written in high level language(or assembly language) into machine code is called language translator or language processor”

Types of Language Processors Compiler Interpreter Assembler

Difference between Compiler & Interpreter Compiler translates the source code into object code as a whole, while interpreter translates the source code into machine code statement by statement Compiler creates an object file while interpreter does not create object file

References Introduction to Information Technology by Riaz Shahid, CM Aslam and Safia Iftikhar The Concepts of Information Technology by Imran Saeed, Ahsan Raza, Tariq Mehmood and Zafar Hussain