SlideShare a Scribd company logo
1 of 35
CSC240
INTRODUCTION TO PROGRAMMING – I
Mr. Dilawar
Lecturer,
Department of Computer Science,
Jahan University
Kabul, Afghanistan.
Course Objectives
• After successfully completing this course, you will be able to:
• What is a computer system and how it works.
• Flow charts and Algorithms.
• Computer programming concepts and their implementation in C++ language.
Course Outline
• Introduction to Computer and Programming Languages.
• Elements of C++ Language.
• Control Structures.
• Working and Understanding Arrays.
• Working with Structures, Union and Enumeration.
Text Books to Follow
• Dietal & Dietal, C/C++: How to Program 7th Edition.
• Programming with C++ by CM Aslam & TA Qureshi (Aikmen Series).
• Object oriented programming using C++ by IT Series.
Lecture Outline
• Introduction to computers and computer organization
• Personal, Distributed and Client/Server Computing
• Programming languages
• Components of programming languages
• Programming techniques
Introduction to Computer
• An electronic machine that can perform computations and logical
decisions at a speed of millions and even billions of times faster than
human being.
• Processes data under control sets of instructions called program.
• A program is a set of instructions that is used to perform a specific
task.
• Programs are written by programmer.
• Programming Languages are the source through which a
programmer writes and develops computer programs.
Introduction to Computer
• Computers are comprised of two parts:
• Hardware-
• Software
Hardware
Electronics circuit boards
that provide
functionality of the system
Software
Program consists
of sets of instructions
that control the system
Computer Organization
Control Unit
Datapath
Arithmetic
Logic Unit
(ALU)
Registers
Processor (CPU)
Computer Organization
• Input Unit
• Receiving section of the computer.
• Gets data from various devices and places.
• Data is entered into computer with the help of mouse & keyboard.
• Data can also be entered in the form of voice and images via scanner and
microphone.
Computer Organization
• Output Unit
• Shaping section of the computer.
• Takes information from CPU and places it on various output devices.
• Information can be viewed either on screens or printed papers.
Computer Organization
• Memory Unit
• Short time warehouse section of computer.
• It keeps the data that has been entered so that it can be available for
processing.
• It also keeps the processed data so that information can be placed on output
devices by output unit.
Computer Organization
• Arithmetic & Logic Unit
• Manufacturing section of computer.
• It is responsible for calculations and logical operations.
• Calculation involves addition, subtraction, multiplication and division.
Computer Organization
• Control Unit
• Administrative section of computer.
• It supervises the operations of the other sections.
• It control and allocates jobs for all other units.
• Many of today’s computers have multiple CPUs and, hence, can perform
many operations simultaneously – multicore processors.
• Dual-core processors – Two CPU’s
• Quad-core processors – Four CPU’s
Computer Organization
• Registers
• Storage location in CPU, used to hold data or a memory address during the
execution of an instruction.
Computer Organization
• Secondary Unit
• Long time warehouse section of computer
• Program and data that are not actively used by the other units are normally
placed on secondary storage time.
• It stores the data permanently for future time.
• Non-Volatile Memory
Personal, Distributed and Client/Server
Computing
• Using desktop and laptop computers for personal use – Personal
computing.
• In 1977, Apple computer popularized Personal computing.
• In 1981, IBM the world’s largest computer vender, introduced the
IBM Personal Computer.
• Stand-alone – transported disks back and forth between them –
Sneakernet.
Personal, Distributed and Client/Server
Computing
• Machines could be linked together in computer networks, over
telephone lines in LANs that led to the phenomenon of distributed
computing.
• Distributed computing is a model in which components of a software
system are shared among multiple computers to improve efficiency
and performance.
Personal, Distributed and Client/Server
Computing
• In Client/Server computing:
• Servers provides services such as file servers, database servers, web servers
and etc…
• Client computers uses the services provided by the server.
Programming Languages
• A programming language is used to write computer programs.
• It is an artificial language designed to communicate instructions to a
machine.
• Some of them are directly understandable by computer and some of
them are needed to be converted first.
Programming Languages
• Computer languages are divided into three broad types:
• Machine Language
• Assembly Language
• High-Level Language
Programming Languages
• Machine Languages
• A computer understands machine language.
• Machine language is also called binary language.
• It is consist of two digits that instructs computers to perform their operations.
• They are machine-dependent.
• No translation is required – directly understandable by computer.
• They are hard to learn and understand.
Programming Languages
Programming Languages
• Assembly Language
• A language in which instead of binary codes we use English like abbreviations
(mnemonics) to represent the operations for the computer.
• A language that uses symbolic names to represent operations, registers and
memory locations.
• It uses a translator called Assembler.
Programming Languages
Programming Languages
• High-Level Language
• A language in which the instructions are written in the form of everyday
English and contain commonly used mathematical notations.
• Compiler and Interpreter are used to covert the high-level code to machine
code.
Programming Languages
Programming Languages
Hierarchy of Languages
Language Representations
Components of Programming Languages
• Syntax
• It is about the structure of the grammar of the language.
• In programming language, the rules and regulations for writing code are
called the syntax.
• A syntax can be used to construct a valid sentence/statement.
Components of Programming Languages
• Semantic
• It describes the meaning of the sentence.
• It describes that whether the sentence is correct or not. If so, what does the
sentence mean?
Categories of Programming Languages
• Major programming languages falls in the category of:
• Structured Programming Languages
• Modular Programming Languages
• Object-Oriented Programming Languages
Categories of Programming Languages
• Structured Programming Languages
• Languages in which the program is divided into smaller components –
functions.
• The structured programming contains three major concepts that are:
• Top-down Design / Divide and Conquer
• Code Reusability
• Information Hiding
Categories of Programming Languages
• Modular Programming Languages
• Languages in which the program is broken into individual components called
modules that can be programmed and tested independently.
Categories of Programming Languages
• Object-Oriented Programming Languages
• Languages in which object technology is supported.
• It allows the pieces of software to be reused and interchanged between
programs.
• The major concepts used in OOP are:
• Data Abstraction – Describes user defined datatypes.
• Encapsulation – Information Hiding
• Inheritance – Describes the reusability of a class.
• Polymorphism – Describes the ability to produce different results based on the object
that is sent to.
Summery
• Introduction to computers and computer organization
• Personal, distributed, and client/server computing
• Programming languages
• Components of programming languages
• Categories of programming languages
Thank You
For your Patience

More Related Content

What's hot

Introduction to computer programming
Introduction to computer programmingIntroduction to computer programming
Introduction to computer programmingNSU-Biliran Campus
 
6 input output devices
6 input output devices6 input output devices
6 input output devicesBaliThorat1
 
Computer Programming
Computer ProgrammingComputer Programming
Computer Programmingbhuttosalman
 
Introduction to Computers Lecture # 11
Introduction to Computers Lecture # 11Introduction to Computers Lecture # 11
Introduction to Computers Lecture # 11Sehrish Rafiq
 
INTRODUCTION TO COMPUTER SOFTWARE
INTRODUCTION TO COMPUTER SOFTWAREINTRODUCTION TO COMPUTER SOFTWARE
INTRODUCTION TO COMPUTER SOFTWAREabiramiabi21
 
Computer generation and classification
Computer generation and classificationComputer generation and classification
Computer generation and classificationBaliThorat1
 
1 fundamentals of computer system
1 fundamentals of computer system1 fundamentals of computer system
1 fundamentals of computer systemBaliThorat1
 
1 fundamentals of computer
1 fundamentals of computer1 fundamentals of computer
1 fundamentals of computerBaliThorat1
 
Introduction to Computers Lecture # 8
Introduction to Computers Lecture # 8Introduction to Computers Lecture # 8
Introduction to Computers Lecture # 8Sehrish Rafiq
 
C++ Training - Lecture 01
C++ Training - Lecture 01C++ Training - Lecture 01
C++ Training - Lecture 01Babak Farhang
 
8 operating system concept
8 operating system concept8 operating system concept
8 operating system conceptBaliThorat1
 
Software languages and devices
Software languages and devicesSoftware languages and devices
Software languages and devicesYogeshSorot
 
Computer Fundamentals & Intro to C Programming module i
Computer Fundamentals & Intro to C Programming module iComputer Fundamentals & Intro to C Programming module i
Computer Fundamentals & Intro to C Programming module iAjit Nayak
 
01 introduction zhu
01 introduction zhu01 introduction zhu
01 introduction zhuc09271
 
Unit 2 computer software
Unit 2 computer softwareUnit 2 computer software
Unit 2 computer softwareHardik Patel
 
Levels of programming languages
Levels of programming languagesLevels of programming languages
Levels of programming languagesMOHSIN BANGI
 

What's hot (20)

[HK Roni] C Programming Lectures
[HK Roni] C Programming Lectures[HK Roni] C Programming Lectures
[HK Roni] C Programming Lectures
 
Introduction to computer programming
Introduction to computer programmingIntroduction to computer programming
Introduction to computer programming
 
6 input output devices
6 input output devices6 input output devices
6 input output devices
 
Computer Programming
Computer ProgrammingComputer Programming
Computer Programming
 
Introduction to Computers Lecture # 11
Introduction to Computers Lecture # 11Introduction to Computers Lecture # 11
Introduction to Computers Lecture # 11
 
7 processor
7 processor7 processor
7 processor
 
INTRODUCTION TO COMPUTER SOFTWARE
INTRODUCTION TO COMPUTER SOFTWAREINTRODUCTION TO COMPUTER SOFTWARE
INTRODUCTION TO COMPUTER SOFTWARE
 
Computer generation and classification
Computer generation and classificationComputer generation and classification
Computer generation and classification
 
1 fundamentals of computer system
1 fundamentals of computer system1 fundamentals of computer system
1 fundamentals of computer system
 
1 fundamentals of computer
1 fundamentals of computer1 fundamentals of computer
1 fundamentals of computer
 
Introduction to Computers Lecture # 8
Introduction to Computers Lecture # 8Introduction to Computers Lecture # 8
Introduction to Computers Lecture # 8
 
C++ Training - Lecture 01
C++ Training - Lecture 01C++ Training - Lecture 01
C++ Training - Lecture 01
 
8 operating system concept
8 operating system concept8 operating system concept
8 operating system concept
 
Software languages and devices
Software languages and devicesSoftware languages and devices
Software languages and devices
 
2. pl domain
2. pl domain2. pl domain
2. pl domain
 
Computer Fundamentals & Intro to C Programming module i
Computer Fundamentals & Intro to C Programming module iComputer Fundamentals & Intro to C Programming module i
Computer Fundamentals & Intro to C Programming module i
 
01 introduction zhu
01 introduction zhu01 introduction zhu
01 introduction zhu
 
Unit 2 computer software
Unit 2 computer softwareUnit 2 computer software
Unit 2 computer software
 
Levels of programming languages
Levels of programming languagesLevels of programming languages
Levels of programming languages
 
Lecture 4- Computer Software and Languages
Lecture 4- Computer Software and LanguagesLecture 4- Computer Software and Languages
Lecture 4- Computer Software and Languages
 

Viewers also liked

Viewers also liked (17)

Bab iv
Bab ivBab iv
Bab iv
 
Mi visita a SeconLife
Mi visita a SeconLifeMi visita a SeconLife
Mi visita a SeconLife
 
Makers University
Makers UniversityMakers University
Makers University
 
Trabajo mercadeo oscar
Trabajo mercadeo oscarTrabajo mercadeo oscar
Trabajo mercadeo oscar
 
Aula VHDL
Aula VHDLAula VHDL
Aula VHDL
 
Four Migration Options to Ease your SQL server 2005 End-of-Support Pains
Four Migration Options to Ease your SQL server 2005 End-of-Support PainsFour Migration Options to Ease your SQL server 2005 End-of-Support Pains
Four Migration Options to Ease your SQL server 2005 End-of-Support Pains
 
Engage - Επίλυση προβλήματος: Συμπεράσματα
Engage - Επίλυση προβλήματος: ΣυμπεράσματαEngage - Επίλυση προβλήματος: Συμπεράσματα
Engage - Επίλυση προβλήματος: Συμπεράσματα
 
Bejaoui r., paquette g., basque j. et henri f. comment personnaliser l'appren...
Bejaoui r., paquette g., basque j. et henri f. comment personnaliser l'appren...Bejaoui r., paquette g., basque j. et henri f. comment personnaliser l'appren...
Bejaoui r., paquette g., basque j. et henri f. comment personnaliser l'appren...
 
簡報1
簡報1簡報1
簡報1
 
Si 1
Si 1Si 1
Si 1
 
Marketing plan - GetDone
Marketing plan - GetDoneMarketing plan - GetDone
Marketing plan - GetDone
 
Sectores economicos jaime
Sectores economicos jaime Sectores economicos jaime
Sectores economicos jaime
 
S sport oostkamp 2014
S sport oostkamp 2014S sport oostkamp 2014
S sport oostkamp 2014
 
Physics Powerpoint
Physics PowerpointPhysics Powerpoint
Physics Powerpoint
 
Pre production
Pre productionPre production
Pre production
 
Conf.journée licef 2016
Conf.journée licef 2016Conf.journée licef 2016
Conf.journée licef 2016
 
Advertisement Samples - Interactive Bees
Advertisement Samples - Interactive BeesAdvertisement Samples - Interactive Bees
Advertisement Samples - Interactive Bees
 

Similar to Csc240 lecture 1

Python-unit -I.pptx
Python-unit -I.pptxPython-unit -I.pptx
Python-unit -I.pptxcrAmth
 
Problem Solving and Program Design in C_1.pdf
Problem Solving and Program Design in C_1.pdfProblem Solving and Program Design in C_1.pdf
Problem Solving and Program Design in C_1.pdfjlu08167
 
Programming requirements for beginning in software engineering.pptx
Programming requirements for beginning in software engineering.pptxProgramming requirements for beginning in software engineering.pptx
Programming requirements for beginning in software engineering.pptxTeddyDaka
 
Desired language characteristics – Data typing .pptx
Desired language characteristics – Data typing .pptxDesired language characteristics – Data typing .pptx
Desired language characteristics – Data typing .pptx4132lenin6497ram
 
Introduction to computer programming
Introduction to computer programming Introduction to computer programming
Introduction to computer programming VanessaBuensalida
 
Programming for Problem Solving
Programming for Problem SolvingProgramming for Problem Solving
Programming for Problem SolvingSukhendra Singh
 
Mca i-fundamental of computer-u-2- application and system software
Mca  i-fundamental of  computer-u-2- application and system softwareMca  i-fundamental of  computer-u-2- application and system software
Mca i-fundamental of computer-u-2- application and system softwareRai University
 
Bca i-fundamental of computer-u-2- application and system software
Bca  i-fundamental of  computer-u-2- application and system softwareBca  i-fundamental of  computer-u-2- application and system software
Bca i-fundamental of computer-u-2- application and system softwareRai University
 
Introduction to computer programming
Introduction to computer programmingIntroduction to computer programming
Introduction to computer programmingSangheethaa Sukumaran
 
Bsc cs 1 fit u-2 application and system software
Bsc cs 1 fit u-2 application and system softwareBsc cs 1 fit u-2 application and system software
Bsc cs 1 fit u-2 application and system softwareRai University
 
Bba i-introduction to computer-u-2- application and system software
Bba  i-introduction to computer-u-2- application and system softwareBba  i-introduction to computer-u-2- application and system software
Bba i-introduction to computer-u-2- application and system softwareRai University
 
Embedded c c++ programming fundamentals master
Embedded c c++ programming fundamentals masterEmbedded c c++ programming fundamentals master
Embedded c c++ programming fundamentals masterHossam Hassan
 

Similar to Csc240 lecture 1 (20)

Python-unit -I.pptx
Python-unit -I.pptxPython-unit -I.pptx
Python-unit -I.pptx
 
Problem Solving and Program Design in C_1.pdf
Problem Solving and Program Design in C_1.pdfProblem Solving and Program Design in C_1.pdf
Problem Solving and Program Design in C_1.pdf
 
Programming requirements for beginning in software engineering.pptx
Programming requirements for beginning in software engineering.pptxProgramming requirements for beginning in software engineering.pptx
Programming requirements for beginning in software engineering.pptx
 
Desired language characteristics – Data typing .pptx
Desired language characteristics – Data typing .pptxDesired language characteristics – Data typing .pptx
Desired language characteristics – Data typing .pptx
 
Ahmadalsawad
AhmadalsawadAhmadalsawad
Ahmadalsawad
 
sege.pdf
sege.pdfsege.pdf
sege.pdf
 
Introduction to computer programming
Introduction to computer programming Introduction to computer programming
Introduction to computer programming
 
Program Logic and Design
Program Logic and DesignProgram Logic and Design
Program Logic and Design
 
programming.pptx
programming.pptxprogramming.pptx
programming.pptx
 
SYSTEM SOFTWARE
SYSTEM SOFTWARE SYSTEM SOFTWARE
SYSTEM SOFTWARE
 
Programming for Problem Solving
Programming for Problem SolvingProgramming for Problem Solving
Programming for Problem Solving
 
lec 1.pptx
lec 1.pptxlec 1.pptx
lec 1.pptx
 
Mca i-fundamental of computer-u-2- application and system software
Mca  i-fundamental of  computer-u-2- application and system softwareMca  i-fundamental of  computer-u-2- application and system software
Mca i-fundamental of computer-u-2- application and system software
 
a1.pptx.pdf
a1.pptx.pdfa1.pptx.pdf
a1.pptx.pdf
 
Compilers.pptx
Compilers.pptxCompilers.pptx
Compilers.pptx
 
Bca i-fundamental of computer-u-2- application and system software
Bca  i-fundamental of  computer-u-2- application and system softwareBca  i-fundamental of  computer-u-2- application and system software
Bca i-fundamental of computer-u-2- application and system software
 
Introduction to computer programming
Introduction to computer programmingIntroduction to computer programming
Introduction to computer programming
 
Bsc cs 1 fit u-2 application and system software
Bsc cs 1 fit u-2 application and system softwareBsc cs 1 fit u-2 application and system software
Bsc cs 1 fit u-2 application and system software
 
Bba i-introduction to computer-u-2- application and system software
Bba  i-introduction to computer-u-2- application and system softwareBba  i-introduction to computer-u-2- application and system software
Bba i-introduction to computer-u-2- application and system software
 
Embedded c c++ programming fundamentals master
Embedded c c++ programming fundamentals masterEmbedded c c++ programming fundamentals master
Embedded c c++ programming fundamentals master
 

More from Ainuddin Yousufzai

More from Ainuddin Yousufzai (16)

Chapter04 ip addressing networking
Chapter04 ip addressing networkingChapter04 ip addressing networking
Chapter04 ip addressing networking
 
Chapter 02 topology networking
Chapter 02  topology networkingChapter 02  topology networking
Chapter 02 topology networking
 
Chapter 01 networking
Chapter 01 networkingChapter 01 networking
Chapter 01 networking
 
Chapter08 internet & multimedia (b)
Chapter08   internet & multimedia (b)Chapter08   internet & multimedia (b)
Chapter08 internet & multimedia (b)
 
Chapter08 internet & multimedia (a)
Chapter08   internet & multimedia (a)Chapter08   internet & multimedia (a)
Chapter08 internet & multimedia (a)
 
Chapter07 io devices
Chapter07   io devicesChapter07   io devices
Chapter07 io devices
 
Chapter06 computer software
Chapter06   computer softwareChapter06   computer software
Chapter06 computer software
 
Chapter05 secondary storage
Chapter05   secondary storageChapter05   secondary storage
Chapter05 secondary storage
 
Chapter04 processor and memory
Chapter04   processor and memoryChapter04   processor and memory
Chapter04 processor and memory
 
Chapter03 number system
Chapter03   number systemChapter03   number system
Chapter03 number system
 
Chapter02 basic computer organization
Chapter02   basic computer organizationChapter02   basic computer organization
Chapter02 basic computer organization
 
Chapter01 introduction to computer
Chapter01   introduction to computerChapter01   introduction to computer
Chapter01 introduction to computer
 
Csc240 -lecture_5
Csc240  -lecture_5Csc240  -lecture_5
Csc240 -lecture_5
 
Csc240 -lecture_4
Csc240  -lecture_4Csc240  -lecture_4
Csc240 -lecture_4
 
Csc240 -lecture_3
Csc240  -lecture_3Csc240  -lecture_3
Csc240 -lecture_3
 
Csc240 -lecture_2
Csc240  -lecture_2Csc240  -lecture_2
Csc240 -lecture_2
 

Recently uploaded

Student Profile Sample - We help schools to connect the data they have, with ...
Student Profile Sample - We help schools to connect the data they have, with ...Student Profile Sample - We help schools to connect the data they have, with ...
Student Profile Sample - We help schools to connect the data they have, with ...Seán Kennedy
 
4.16.24 Poverty and Precarity--Desmond.pptx
4.16.24 Poverty and Precarity--Desmond.pptx4.16.24 Poverty and Precarity--Desmond.pptx
4.16.24 Poverty and Precarity--Desmond.pptxmary850239
 
EMBODO Lesson Plan Grade 9 Law of Sines.docx
EMBODO Lesson Plan Grade 9 Law of Sines.docxEMBODO Lesson Plan Grade 9 Law of Sines.docx
EMBODO Lesson Plan Grade 9 Law of Sines.docxElton John Embodo
 
Expanded definition: technical and operational
Expanded definition: technical and operationalExpanded definition: technical and operational
Expanded definition: technical and operationalssuser3e220a
 
Integumentary System SMP B. Pharm Sem I.ppt
Integumentary System SMP B. Pharm Sem I.pptIntegumentary System SMP B. Pharm Sem I.ppt
Integumentary System SMP B. Pharm Sem I.pptshraddhaparab530
 
How to Add Barcode on PDF Report in Odoo 17
How to Add Barcode on PDF Report in Odoo 17How to Add Barcode on PDF Report in Odoo 17
How to Add Barcode on PDF Report in Odoo 17Celine George
 
Choosing the Right CBSE School A Comprehensive Guide for Parents
Choosing the Right CBSE School A Comprehensive Guide for ParentsChoosing the Right CBSE School A Comprehensive Guide for Parents
Choosing the Right CBSE School A Comprehensive Guide for Parentsnavabharathschool99
 
GRADE 4 - SUMMATIVE TEST QUARTER 4 ALL SUBJECTS
GRADE 4 - SUMMATIVE TEST QUARTER 4 ALL SUBJECTSGRADE 4 - SUMMATIVE TEST QUARTER 4 ALL SUBJECTS
GRADE 4 - SUMMATIVE TEST QUARTER 4 ALL SUBJECTSJoshuaGantuangco2
 
Presentation Activity 2. Unit 3 transv.pptx
Presentation Activity 2. Unit 3 transv.pptxPresentation Activity 2. Unit 3 transv.pptx
Presentation Activity 2. Unit 3 transv.pptxRosabel UA
 
Active Learning Strategies (in short ALS).pdf
Active Learning Strategies (in short ALS).pdfActive Learning Strategies (in short ALS).pdf
Active Learning Strategies (in short ALS).pdfPatidar M
 
4.18.24 Movement Legacies, Reflection, and Review.pptx
4.18.24 Movement Legacies, Reflection, and Review.pptx4.18.24 Movement Legacies, Reflection, and Review.pptx
4.18.24 Movement Legacies, Reflection, and Review.pptxmary850239
 
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdf
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdfInclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdf
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdfTechSoup
 
ANG SEKTOR NG agrikultura.pptx QUARTER 4
ANG SEKTOR NG agrikultura.pptx QUARTER 4ANG SEKTOR NG agrikultura.pptx QUARTER 4
ANG SEKTOR NG agrikultura.pptx QUARTER 4MiaBumagat1
 
Measures of Position DECILES for ungrouped data
Measures of Position DECILES for ungrouped dataMeasures of Position DECILES for ungrouped data
Measures of Position DECILES for ungrouped dataBabyAnnMotar
 
4.16.24 21st Century Movements for Black Lives.pptx
4.16.24 21st Century Movements for Black Lives.pptx4.16.24 21st Century Movements for Black Lives.pptx
4.16.24 21st Century Movements for Black Lives.pptxmary850239
 
ICS2208 Lecture6 Notes for SL spaces.pdf
ICS2208 Lecture6 Notes for SL spaces.pdfICS2208 Lecture6 Notes for SL spaces.pdf
ICS2208 Lecture6 Notes for SL spaces.pdfVanessa Camilleri
 
Dust Of Snow By Robert Frost Class-X English CBSE
Dust Of Snow By Robert Frost Class-X English CBSEDust Of Snow By Robert Frost Class-X English CBSE
Dust Of Snow By Robert Frost Class-X English CBSEaurabinda banchhor
 

Recently uploaded (20)

Student Profile Sample - We help schools to connect the data they have, with ...
Student Profile Sample - We help schools to connect the data they have, with ...Student Profile Sample - We help schools to connect the data they have, with ...
Student Profile Sample - We help schools to connect the data they have, with ...
 
4.16.24 Poverty and Precarity--Desmond.pptx
4.16.24 Poverty and Precarity--Desmond.pptx4.16.24 Poverty and Precarity--Desmond.pptx
4.16.24 Poverty and Precarity--Desmond.pptx
 
EMBODO Lesson Plan Grade 9 Law of Sines.docx
EMBODO Lesson Plan Grade 9 Law of Sines.docxEMBODO Lesson Plan Grade 9 Law of Sines.docx
EMBODO Lesson Plan Grade 9 Law of Sines.docx
 
Expanded definition: technical and operational
Expanded definition: technical and operationalExpanded definition: technical and operational
Expanded definition: technical and operational
 
Integumentary System SMP B. Pharm Sem I.ppt
Integumentary System SMP B. Pharm Sem I.pptIntegumentary System SMP B. Pharm Sem I.ppt
Integumentary System SMP B. Pharm Sem I.ppt
 
How to Add Barcode on PDF Report in Odoo 17
How to Add Barcode on PDF Report in Odoo 17How to Add Barcode on PDF Report in Odoo 17
How to Add Barcode on PDF Report in Odoo 17
 
Choosing the Right CBSE School A Comprehensive Guide for Parents
Choosing the Right CBSE School A Comprehensive Guide for ParentsChoosing the Right CBSE School A Comprehensive Guide for Parents
Choosing the Right CBSE School A Comprehensive Guide for Parents
 
GRADE 4 - SUMMATIVE TEST QUARTER 4 ALL SUBJECTS
GRADE 4 - SUMMATIVE TEST QUARTER 4 ALL SUBJECTSGRADE 4 - SUMMATIVE TEST QUARTER 4 ALL SUBJECTS
GRADE 4 - SUMMATIVE TEST QUARTER 4 ALL SUBJECTS
 
Paradigm shift in nursing research by RS MEHTA
Paradigm shift in nursing research by RS MEHTAParadigm shift in nursing research by RS MEHTA
Paradigm shift in nursing research by RS MEHTA
 
Presentation Activity 2. Unit 3 transv.pptx
Presentation Activity 2. Unit 3 transv.pptxPresentation Activity 2. Unit 3 transv.pptx
Presentation Activity 2. Unit 3 transv.pptx
 
Active Learning Strategies (in short ALS).pdf
Active Learning Strategies (in short ALS).pdfActive Learning Strategies (in short ALS).pdf
Active Learning Strategies (in short ALS).pdf
 
FINALS_OF_LEFT_ON_C'N_EL_DORADO_2024.pptx
FINALS_OF_LEFT_ON_C'N_EL_DORADO_2024.pptxFINALS_OF_LEFT_ON_C'N_EL_DORADO_2024.pptx
FINALS_OF_LEFT_ON_C'N_EL_DORADO_2024.pptx
 
YOUVE GOT EMAIL_FINALS_EL_DORADO_2024.pptx
YOUVE GOT EMAIL_FINALS_EL_DORADO_2024.pptxYOUVE GOT EMAIL_FINALS_EL_DORADO_2024.pptx
YOUVE GOT EMAIL_FINALS_EL_DORADO_2024.pptx
 
4.18.24 Movement Legacies, Reflection, and Review.pptx
4.18.24 Movement Legacies, Reflection, and Review.pptx4.18.24 Movement Legacies, Reflection, and Review.pptx
4.18.24 Movement Legacies, Reflection, and Review.pptx
 
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdf
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdfInclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdf
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdf
 
ANG SEKTOR NG agrikultura.pptx QUARTER 4
ANG SEKTOR NG agrikultura.pptx QUARTER 4ANG SEKTOR NG agrikultura.pptx QUARTER 4
ANG SEKTOR NG agrikultura.pptx QUARTER 4
 
Measures of Position DECILES for ungrouped data
Measures of Position DECILES for ungrouped dataMeasures of Position DECILES for ungrouped data
Measures of Position DECILES for ungrouped data
 
4.16.24 21st Century Movements for Black Lives.pptx
4.16.24 21st Century Movements for Black Lives.pptx4.16.24 21st Century Movements for Black Lives.pptx
4.16.24 21st Century Movements for Black Lives.pptx
 
ICS2208 Lecture6 Notes for SL spaces.pdf
ICS2208 Lecture6 Notes for SL spaces.pdfICS2208 Lecture6 Notes for SL spaces.pdf
ICS2208 Lecture6 Notes for SL spaces.pdf
 
Dust Of Snow By Robert Frost Class-X English CBSE
Dust Of Snow By Robert Frost Class-X English CBSEDust Of Snow By Robert Frost Class-X English CBSE
Dust Of Snow By Robert Frost Class-X English CBSE
 

Csc240 lecture 1

  • 1. CSC240 INTRODUCTION TO PROGRAMMING – I Mr. Dilawar Lecturer, Department of Computer Science, Jahan University Kabul, Afghanistan.
  • 2. Course Objectives • After successfully completing this course, you will be able to: • What is a computer system and how it works. • Flow charts and Algorithms. • Computer programming concepts and their implementation in C++ language.
  • 3. Course Outline • Introduction to Computer and Programming Languages. • Elements of C++ Language. • Control Structures. • Working and Understanding Arrays. • Working with Structures, Union and Enumeration.
  • 4. Text Books to Follow • Dietal & Dietal, C/C++: How to Program 7th Edition. • Programming with C++ by CM Aslam & TA Qureshi (Aikmen Series). • Object oriented programming using C++ by IT Series.
  • 5. Lecture Outline • Introduction to computers and computer organization • Personal, Distributed and Client/Server Computing • Programming languages • Components of programming languages • Programming techniques
  • 6. Introduction to Computer • An electronic machine that can perform computations and logical decisions at a speed of millions and even billions of times faster than human being. • Processes data under control sets of instructions called program. • A program is a set of instructions that is used to perform a specific task. • Programs are written by programmer. • Programming Languages are the source through which a programmer writes and develops computer programs.
  • 7. Introduction to Computer • Computers are comprised of two parts: • Hardware- • Software Hardware Electronics circuit boards that provide functionality of the system Software Program consists of sets of instructions that control the system
  • 9. Computer Organization • Input Unit • Receiving section of the computer. • Gets data from various devices and places. • Data is entered into computer with the help of mouse & keyboard. • Data can also be entered in the form of voice and images via scanner and microphone.
  • 10. Computer Organization • Output Unit • Shaping section of the computer. • Takes information from CPU and places it on various output devices. • Information can be viewed either on screens or printed papers.
  • 11. Computer Organization • Memory Unit • Short time warehouse section of computer. • It keeps the data that has been entered so that it can be available for processing. • It also keeps the processed data so that information can be placed on output devices by output unit.
  • 12. Computer Organization • Arithmetic & Logic Unit • Manufacturing section of computer. • It is responsible for calculations and logical operations. • Calculation involves addition, subtraction, multiplication and division.
  • 13. Computer Organization • Control Unit • Administrative section of computer. • It supervises the operations of the other sections. • It control and allocates jobs for all other units. • Many of today’s computers have multiple CPUs and, hence, can perform many operations simultaneously – multicore processors. • Dual-core processors – Two CPU’s • Quad-core processors – Four CPU’s
  • 14. Computer Organization • Registers • Storage location in CPU, used to hold data or a memory address during the execution of an instruction.
  • 15. Computer Organization • Secondary Unit • Long time warehouse section of computer • Program and data that are not actively used by the other units are normally placed on secondary storage time. • It stores the data permanently for future time. • Non-Volatile Memory
  • 16. Personal, Distributed and Client/Server Computing • Using desktop and laptop computers for personal use – Personal computing. • In 1977, Apple computer popularized Personal computing. • In 1981, IBM the world’s largest computer vender, introduced the IBM Personal Computer. • Stand-alone – transported disks back and forth between them – Sneakernet.
  • 17. Personal, Distributed and Client/Server Computing • Machines could be linked together in computer networks, over telephone lines in LANs that led to the phenomenon of distributed computing. • Distributed computing is a model in which components of a software system are shared among multiple computers to improve efficiency and performance.
  • 18. Personal, Distributed and Client/Server Computing • In Client/Server computing: • Servers provides services such as file servers, database servers, web servers and etc… • Client computers uses the services provided by the server.
  • 19. Programming Languages • A programming language is used to write computer programs. • It is an artificial language designed to communicate instructions to a machine. • Some of them are directly understandable by computer and some of them are needed to be converted first.
  • 20. Programming Languages • Computer languages are divided into three broad types: • Machine Language • Assembly Language • High-Level Language
  • 21. Programming Languages • Machine Languages • A computer understands machine language. • Machine language is also called binary language. • It is consist of two digits that instructs computers to perform their operations. • They are machine-dependent. • No translation is required – directly understandable by computer. • They are hard to learn and understand.
  • 23. Programming Languages • Assembly Language • A language in which instead of binary codes we use English like abbreviations (mnemonics) to represent the operations for the computer. • A language that uses symbolic names to represent operations, registers and memory locations. • It uses a translator called Assembler.
  • 25. Programming Languages • High-Level Language • A language in which the instructions are written in the form of everyday English and contain commonly used mathematical notations. • Compiler and Interpreter are used to covert the high-level code to machine code.
  • 27. Programming Languages Hierarchy of Languages Language Representations
  • 28. Components of Programming Languages • Syntax • It is about the structure of the grammar of the language. • In programming language, the rules and regulations for writing code are called the syntax. • A syntax can be used to construct a valid sentence/statement.
  • 29. Components of Programming Languages • Semantic • It describes the meaning of the sentence. • It describes that whether the sentence is correct or not. If so, what does the sentence mean?
  • 30. Categories of Programming Languages • Major programming languages falls in the category of: • Structured Programming Languages • Modular Programming Languages • Object-Oriented Programming Languages
  • 31. Categories of Programming Languages • Structured Programming Languages • Languages in which the program is divided into smaller components – functions. • The structured programming contains three major concepts that are: • Top-down Design / Divide and Conquer • Code Reusability • Information Hiding
  • 32. Categories of Programming Languages • Modular Programming Languages • Languages in which the program is broken into individual components called modules that can be programmed and tested independently.
  • 33. Categories of Programming Languages • Object-Oriented Programming Languages • Languages in which object technology is supported. • It allows the pieces of software to be reused and interchanged between programs. • The major concepts used in OOP are: • Data Abstraction – Describes user defined datatypes. • Encapsulation – Information Hiding • Inheritance – Describes the reusability of a class. • Polymorphism – Describes the ability to produce different results based on the object that is sent to.
  • 34. Summery • Introduction to computers and computer organization • Personal, distributed, and client/server computing • Programming languages • Components of programming languages • Categories of programming languages
  • 35. Thank You For your Patience