SlideShare a Scribd company logo
1 of 15
Dr B T Sampath Kumar
Professor
Department of Library and Information Science
Tumkur University, Tumakuru, INDIA
www.sampathkumar.info
Programming
Programing
• Program is a set of instructions.
• Programming is a process of creating a set of
instructions that tell a computer how to
perform a task.
• Programming can be done using a variety of
computer languages, such as C, C++, Java,
HTML etc.
• Collection of program is software.
Steps in programming
• Understanding the problem.
• Design a solution.
• Write algorithm and draw flowchart.
• Coding.
• Programming testing and debugging.
• Documentation.
Understanding the problem
• This is the first step in programming.
• The programmer should understand the
problem thoroughly in terms of requirements
i.e. what is the:
– input and
– output operations to be performed.
• If the problem is not properly interpreted then
it is not possible to obtain the desired results.
Design a solution
• Once the problem is thoroughly understood,
then it is necessary to plan for the method of
solution.
• Depending upon the size of the task, the
program preparation may be shared amongst
many programmers.
Cont..
• Large programs may require each programmer
to write a separate part of the program.
• These separate parts are often called as
modules or segments.
• These modules may be prepared and tested
separately, then linked together and tested as
a whole program.
Write Algorithm and draw Flowchart
• An algorithm is non-computer language.
• It is a problem solving technique.
• It can be defined as a “step by step procedure
to solve a particular problem”.
Algorithm to add two numbers
• Step 1: Read two numbers a, b
• Step 2: Add two numbers (c=a+b)
• Step 3: Print the sum, c
• Step 4: End of algorithm
• Step 5: Stop
Algorithm to calculate the area of a
triangle
• Step 1: Start
• Step 2: Read length and breadth
• Step 3: a=1/2*b*l
• Step 4: Print ‘a’
• Step 5: Stop
Breadth (b)
L
e
n
gt
h
(l)
Flowcharting
• Flowcharting is a method of representing with
symbols, their operation and their sequence
of execution in information processing.
Symbols used in Flowchart
Start/Stop
General processing
ConnectorInput/output
Decision
Flowchart to add three numbers
Read the
numbers
Coding
• The process of writing computer instructions in a
programming language (C or C++) is known as
Coding.
Program written in C is as follows:
int main()
{
int a,b,c,d;
printf(“Enter any three numbers");
scanf("%d%d%d", &a, &b, &c);
d=(a+b+c);
printf("The sum of three number is = %dn",d);
}
Program testing and debugging
• The programmer might have made logical
errors in sequencing or perhaps errors were
made in entering the code.
• The process of correcting such errors is called
debugging.
Documentation
• For a programmer reliable documentation is
always a must.
• The presence of documentation helps keep
track of all aspects of an application and
it improves on the quality of a software
product.
• Its main focuses are development,
maintenance and knowledge transfer to other
developers.

More Related Content

What's hot

Introduction to Computers Lecture # 12
Introduction to Computers Lecture # 12Introduction to Computers Lecture # 12
Introduction to Computers Lecture # 12Sehrish Rafiq
 
Computer-charecteristics,types of languages,translators
Computer-charecteristics,types of languages,translatorsComputer-charecteristics,types of languages,translators
Computer-charecteristics,types of languages,translatorsVarshaSivashanker
 
Introductiontocomputerprogramming 140713205433-phpapp02
Introductiontocomputerprogramming 140713205433-phpapp02Introductiontocomputerprogramming 140713205433-phpapp02
Introductiontocomputerprogramming 140713205433-phpapp02Lanie Plecerda
 
Lecture 5 - Structured Programming Language
Lecture 5 - Structured Programming Language Lecture 5 - Structured Programming Language
Lecture 5 - Structured Programming Language Md. Imran Hossain Showrov
 
Introduction to computer programming
Introduction to computer programmingIntroduction to computer programming
Introduction to computer programmingNSU-Biliran Campus
 
Programming for Problem Solving
Programming for Problem SolvingProgramming for Problem Solving
Programming for Problem SolvingSukhendra Singh
 
system software and application software, compiler, interpreter & assembler
system software  and application software, compiler, interpreter & assemblersystem software  and application software, compiler, interpreter & assembler
system software and application software, compiler, interpreter & assemblerchetan birla
 
Basic terms used in microprocessor
Basic terms used in microprocessorBasic terms used in microprocessor
Basic terms used in microprocessorRamaPrabha24
 
Computer Programs & System Softwares
Computer Programs & System SoftwaresComputer Programs & System Softwares
Computer Programs & System SoftwaresAbijah Naresh Jumani
 
Chapter 1: Intro to Funds of Programming
Chapter 1: Intro to Funds of ProgrammingChapter 1: Intro to Funds of Programming
Chapter 1: Intro to Funds of Programmingricsanmae
 
Ch0 computer systems overview
Ch0 computer systems overviewCh0 computer systems overview
Ch0 computer systems overviewAboubakarIbrahima
 

What's hot (20)

Introduction to Computers Lecture # 12
Introduction to Computers Lecture # 12Introduction to Computers Lecture # 12
Introduction to Computers Lecture # 12
 
Computer-charecteristics,types of languages,translators
Computer-charecteristics,types of languages,translatorsComputer-charecteristics,types of languages,translators
Computer-charecteristics,types of languages,translators
 
Introductiontocomputerprogramming 140713205433-phpapp02
Introductiontocomputerprogramming 140713205433-phpapp02Introductiontocomputerprogramming 140713205433-phpapp02
Introductiontocomputerprogramming 140713205433-phpapp02
 
Lecture 5 - Structured Programming Language
Lecture 5 - Structured Programming Language Lecture 5 - Structured Programming Language
Lecture 5 - Structured Programming Language
 
Lecture 22 - Error Handling
Lecture 22 - Error HandlingLecture 22 - Error Handling
Lecture 22 - Error Handling
 
Introduction to computer programming
Introduction to computer programmingIntroduction to computer programming
Introduction to computer programming
 
Programming for Problem Solving
Programming for Problem SolvingProgramming for Problem Solving
Programming for Problem Solving
 
system software and application software, compiler, interpreter & assembler
system software  and application software, compiler, interpreter & assemblersystem software  and application software, compiler, interpreter & assembler
system software and application software, compiler, interpreter & assembler
 
Lecture 4- Computer Software and Languages
Lecture 4- Computer Software and LanguagesLecture 4- Computer Software and Languages
Lecture 4- Computer Software and Languages
 
Types of system software
Types of system softwareTypes of system software
Types of system software
 
Algorithms - Introduction to computer programming
Algorithms - Introduction to computer programmingAlgorithms - Introduction to computer programming
Algorithms - Introduction to computer programming
 
L2 ch1
L2  ch1L2  ch1
L2 ch1
 
Computer software
Computer softwareComputer software
Computer software
 
Basic terms used in microprocessor
Basic terms used in microprocessorBasic terms used in microprocessor
Basic terms used in microprocessor
 
Introduction to Computer System
Introduction to Computer SystemIntroduction to Computer System
Introduction to Computer System
 
Computer Programs & System Softwares
Computer Programs & System SoftwaresComputer Programs & System Softwares
Computer Programs & System Softwares
 
Software tools
Software toolsSoftware tools
Software tools
 
Chapter 1: Intro to Funds of Programming
Chapter 1: Intro to Funds of ProgrammingChapter 1: Intro to Funds of Programming
Chapter 1: Intro to Funds of Programming
 
Computer definition
Computer definitionComputer definition
Computer definition
 
Ch0 computer systems overview
Ch0 computer systems overviewCh0 computer systems overview
Ch0 computer systems overview
 

Similar to Programming

C programming for Computing Techniques
C programming for Computing TechniquesC programming for Computing Techniques
C programming for Computing TechniquesAppili Vamsi Krishna
 
Algorithmic problem sloving
Algorithmic problem slovingAlgorithmic problem sloving
Algorithmic problem slovingMani Kandan
 
Basic Programming concepts - Programming with C++
Basic Programming concepts - Programming with C++Basic Programming concepts - Programming with C++
Basic Programming concepts - Programming with C++Mohamed El Desouki
 
Unit 1 python (2021 r)
Unit 1 python (2021 r)Unit 1 python (2021 r)
Unit 1 python (2021 r)praveena p
 
Pj01 1-computer and programming fundamentals
Pj01 1-computer and programming fundamentalsPj01 1-computer and programming fundamentals
Pj01 1-computer and programming fundamentalsSasidharaRaoMarrapu
 
Cs1123 2 comp_prog
Cs1123 2 comp_progCs1123 2 comp_prog
Cs1123 2 comp_progTAlha MAlik
 
COM1407: Structured Program Development
COM1407: Structured Program Development COM1407: Structured Program Development
COM1407: Structured Program Development Hemantha Kulathilake
 
Programming_Lecture_1.pptx
Programming_Lecture_1.pptxProgramming_Lecture_1.pptx
Programming_Lecture_1.pptxshoaibkhan716300
 
FIT-Unit3 chapter 1 -computer program
FIT-Unit3 chapter 1 -computer programFIT-Unit3 chapter 1 -computer program
FIT-Unit3 chapter 1 -computer programraksharao
 
L1. Basic Programming Concepts.pdf
L1. Basic Programming Concepts.pdfL1. Basic Programming Concepts.pdf
L1. Basic Programming Concepts.pdfMMRF2
 
BCE L-2 Algorithms-and-Flowchart-ppt.ppt
BCE L-2 Algorithms-and-Flowchart-ppt.pptBCE L-2 Algorithms-and-Flowchart-ppt.ppt
BCE L-2 Algorithms-and-Flowchart-ppt.pptKirti Verma
 

Similar to Programming (20)

Algorithm.pdf
Algorithm.pdfAlgorithm.pdf
Algorithm.pdf
 
C programming for Computing Techniques
C programming for Computing TechniquesC programming for Computing Techniques
C programming for Computing Techniques
 
Programming logic &practices
Programming logic &practices Programming logic &practices
Programming logic &practices
 
Algorithmic problem sloving
Algorithmic problem slovingAlgorithmic problem sloving
Algorithmic problem sloving
 
Basic Programming concepts - Programming with C++
Basic Programming concepts - Programming with C++Basic Programming concepts - Programming with C++
Basic Programming concepts - Programming with C++
 
Unit 1 python (2021 r)
Unit 1 python (2021 r)Unit 1 python (2021 r)
Unit 1 python (2021 r)
 
Pj01 1-computer and programming fundamentals
Pj01 1-computer and programming fundamentalsPj01 1-computer and programming fundamentals
Pj01 1-computer and programming fundamentals
 
PPS Unit-1.pdf
PPS Unit-1.pdfPPS Unit-1.pdf
PPS Unit-1.pdf
 
Programing Fundamental
Programing FundamentalPrograming Fundamental
Programing Fundamental
 
Lecture1
Lecture1Lecture1
Lecture1
 
Problem solving methodology
Problem solving methodologyProblem solving methodology
Problem solving methodology
 
C_Programming_Notes_ICE
C_Programming_Notes_ICEC_Programming_Notes_ICE
C_Programming_Notes_ICE
 
Cs1123 2 comp_prog
Cs1123 2 comp_progCs1123 2 comp_prog
Cs1123 2 comp_prog
 
COM1407: Structured Program Development
COM1407: Structured Program Development COM1407: Structured Program Development
COM1407: Structured Program Development
 
Programming_Lecture_1.pptx
Programming_Lecture_1.pptxProgramming_Lecture_1.pptx
Programming_Lecture_1.pptx
 
FIT-Unit3 chapter 1 -computer program
FIT-Unit3 chapter 1 -computer programFIT-Unit3 chapter 1 -computer program
FIT-Unit3 chapter 1 -computer program
 
L1. Basic Programming Concepts.pdf
L1. Basic Programming Concepts.pdfL1. Basic Programming Concepts.pdf
L1. Basic Programming Concepts.pdf
 
BCE L-2 Algorithms-and-Flowchart-ppt.ppt
BCE L-2 Algorithms-and-Flowchart-ppt.pptBCE L-2 Algorithms-and-Flowchart-ppt.ppt
BCE L-2 Algorithms-and-Flowchart-ppt.ppt
 
Unit 1 psp
Unit 1 pspUnit 1 psp
Unit 1 psp
 
DISE - Programming Concepts
DISE - Programming ConceptsDISE - Programming Concepts
DISE - Programming Concepts
 

More from Dr. B T Sampath Kumar (20)

Selection of scholarly journal in Education
Selection of scholarly journal in EducationSelection of scholarly journal in Education
Selection of scholarly journal in Education
 
Web decay and Internet Archive
Web decay and Internet ArchiveWeb decay and Internet Archive
Web decay and Internet Archive
 
Selection of scholarly journal
Selection of scholarly journal Selection of scholarly journal
Selection of scholarly journal
 
Web browser
Web browserWeb browser
Web browser
 
Types of computer
Types of computerTypes of computer
Types of computer
 
Secondary storage devices
Secondary storage devicesSecondary storage devices
Secondary storage devices
 
Search engine
Search engineSearch engine
Search engine
 
Output devices
Output devicesOutput devices
Output devices
 
Online learning courses
Online learning coursesOnline learning courses
Online learning courses
 
Networks
NetworksNetworks
Networks
 
Network topology
Network topologyNetwork topology
Network topology
 
Network protocols
Network protocolsNetwork protocols
Network protocols
 
Library networks
Library networksLibrary networks
Library networks
 
Internal storage devices
Internal storage devicesInternal storage devices
Internal storage devices
 
Input devices
Input devicesInput devices
Input devices
 
Information and communication technology
Information and communication technologyInformation and communication technology
Information and communication technology
 
Generations of computer
Generations of computerGenerations of computer
Generations of computer
 
Evaluation of search engine
Evaluation of search engineEvaluation of search engine
Evaluation of search engine
 
Electronic communication
Electronic communicationElectronic communication
Electronic communication
 
E commerce
E commerceE commerce
E commerce
 

Recently uploaded

WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure servicePooja Nehwal
 
Snow Chain-Integrated Tire for a Safe Drive on Winter Roads
Snow Chain-Integrated Tire for a Safe Drive on Winter RoadsSnow Chain-Integrated Tire for a Safe Drive on Winter Roads
Snow Chain-Integrated Tire for a Safe Drive on Winter RoadsHyundai Motor Group
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking MenDelhi Call girls
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions
 
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | DelhiFULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhisoniya singh
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking MenDelhi Call girls
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Patryk Bandurski
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slidespraypatel2
 
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...HostedbyConfluent
 
Pigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions
 
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...shyamraj55
 
How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?XfilesPro
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024Scott Keck-Warren
 
Azure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & ApplicationAzure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & ApplicationAndikSusilo4
 
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphNeo4j
 
Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptxLBM Solutions
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsMemoori
 

Recently uploaded (20)

WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
 
Snow Chain-Integrated Tire for a Safe Drive on Winter Roads
Snow Chain-Integrated Tire for a Safe Drive on Winter RoadsSnow Chain-Integrated Tire for a Safe Drive on Winter Roads
Snow Chain-Integrated Tire for a Safe Drive on Winter Roads
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food Manufacturing
 
Vulnerability_Management_GRC_by Sohang Sengupta.pptx
Vulnerability_Management_GRC_by Sohang Sengupta.pptxVulnerability_Management_GRC_by Sohang Sengupta.pptx
Vulnerability_Management_GRC_by Sohang Sengupta.pptx
 
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | DelhiFULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
 
Pigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping Elbows
 
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
 
How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024
 
Azure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & ApplicationAzure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & Application
 
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
 
Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptx
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial Buildings
 

Programming

  • 1. Dr B T Sampath Kumar Professor Department of Library and Information Science Tumkur University, Tumakuru, INDIA www.sampathkumar.info Programming
  • 2. Programing • Program is a set of instructions. • Programming is a process of creating a set of instructions that tell a computer how to perform a task. • Programming can be done using a variety of computer languages, such as C, C++, Java, HTML etc. • Collection of program is software.
  • 3. Steps in programming • Understanding the problem. • Design a solution. • Write algorithm and draw flowchart. • Coding. • Programming testing and debugging. • Documentation.
  • 4. Understanding the problem • This is the first step in programming. • The programmer should understand the problem thoroughly in terms of requirements i.e. what is the: – input and – output operations to be performed. • If the problem is not properly interpreted then it is not possible to obtain the desired results.
  • 5. Design a solution • Once the problem is thoroughly understood, then it is necessary to plan for the method of solution. • Depending upon the size of the task, the program preparation may be shared amongst many programmers.
  • 6. Cont.. • Large programs may require each programmer to write a separate part of the program. • These separate parts are often called as modules or segments. • These modules may be prepared and tested separately, then linked together and tested as a whole program.
  • 7. Write Algorithm and draw Flowchart • An algorithm is non-computer language. • It is a problem solving technique. • It can be defined as a “step by step procedure to solve a particular problem”.
  • 8. Algorithm to add two numbers • Step 1: Read two numbers a, b • Step 2: Add two numbers (c=a+b) • Step 3: Print the sum, c • Step 4: End of algorithm • Step 5: Stop
  • 9. Algorithm to calculate the area of a triangle • Step 1: Start • Step 2: Read length and breadth • Step 3: a=1/2*b*l • Step 4: Print ‘a’ • Step 5: Stop Breadth (b) L e n gt h (l)
  • 10. Flowcharting • Flowcharting is a method of representing with symbols, their operation and their sequence of execution in information processing.
  • 11. Symbols used in Flowchart Start/Stop General processing ConnectorInput/output Decision
  • 12. Flowchart to add three numbers Read the numbers
  • 13. Coding • The process of writing computer instructions in a programming language (C or C++) is known as Coding. Program written in C is as follows: int main() { int a,b,c,d; printf(“Enter any three numbers"); scanf("%d%d%d", &a, &b, &c); d=(a+b+c); printf("The sum of three number is = %dn",d); }
  • 14. Program testing and debugging • The programmer might have made logical errors in sequencing or perhaps errors were made in entering the code. • The process of correcting such errors is called debugging.
  • 15. Documentation • For a programmer reliable documentation is always a must. • The presence of documentation helps keep track of all aspects of an application and it improves on the quality of a software product. • Its main focuses are development, maintenance and knowledge transfer to other developers.