SlideShare a Scribd company logo
1 of 25
Logic Building Techniques
and Practices
Section 2
Hello!
Activity
1. One person hides a piece of “treasure” (this could be anything!) in an
indoor or outdoor space.
2. Next, the treasure hider writes out instructions explaining how to find
the hidden object. The instructions need to be very clear so the finder
knows exactly what to do – otherwise, they won’t get to the treasure!
Example:
○ Take 10 steps STRAIGHT
○ Turn RIGHT and take 5 big hops
○ Turn LEFT and crawl 8 times
○ Dig 2 inches down to find the treasure!
3. Once the instructions are written, the finder follows them exactly.
4. If instructions aren’t clear enough, the hider may need to find the bug
and fix it so the finder can successfully reach the treasure.
5. Switch places when finished.
Merits of Algorithm
● It is easy to understand.
● An algorithm is a step-wise representation of a solution to a
given problem.
● In Algorithm the problem is broken down into smaller pieces or
steps hence, it is easier for the programmer to convert it into an
actual program.
Demerits of Algorithm
● Writing an algorithm takes a long time so it is time-
consuming.
● Understanding complex logic through algorithms can
be very difficult.
● Branching and Looping statements are difficult to
show in Algorithms
Trend 01
75%
What is a process ?
The instance of a computer program that
is being executed by one or many
threads.
A thread is the smallest unit of
processing
Conditional / Decision Statements
● Conditional statements help you to make a decision based on
certain conditions.
● Conditional statements always have an if part, which tells the
what to do when the condition is true.
● Conditional statements also usually have an else part, which
tells the what to do when the condition is false.
Consecteturnec labore Adipiscingelit sed Sed eiusmod
Practice - Algorithm to check even or odd number
● If we divide number by 2 and multiply it by 2 if the number is same
then the number (2*N)
● else the number is odd (2*n+1)
Step 1: Start
Step 2: Read a number to N
Step 3: R= N/2 store the
remainder(R).
Step 4: If R = O Then go to Step 6
Step 5: Print “N is odd” go to step 7
Step 6: Print “N is even”
Step 7: Stop
Follow
Instructions by
Tanya
Algorithm for angry bird - DIV C
Step1 : https://studio.code.org/join
Step 2: type in their section code: HQYKXB
Step3: fill in the details
Step 4: Follow video instructions carefully and complete the
session
Scan for Certificate
Algorithm for angry bird - DIV D
Step1 : https://studio.code.org/join
Step 2: type in their section code: KWJWWJ
Step3: fill in the details
Step 4: Follow video instructions carefully and complete the
session
Loops (Iteration)
0
1
0
2
0
3
a loop is a sequence of instruction s that is
continually repeated until a certain condition
is reached
Pseudo code
● It is a methodology that allows the programmer to
represent the implementation of an algorithm.
● Pseudo code, as the name suggests, is a false code
or a representation of code which can be
understood by even a layman with some school
level programming knowledge.
Example:
if "1"
print response
"I am happy"
if "2"
print response
"You are sad"
Advantages of Pseudocode
● Improves the readability of any approach. It’s one of the best approaches to
start implementation of an algorithm.
● Acts as a bridge between the program and the algorithm or flowchart. Also
works as a rough documentation, so the program of one developer can be
understood easily when a pseudo code is written out. In industries, the
approach of documentation is essential. And that’s where a pseudo-code
proves vital.
● The main goal of a pseudo code is to explain what exactly each line of a
program should do, hence making the code construction phase easier for the
The 3 major functions of the input unit are-
● Take the data to be processed by the user.
● Convert the given data into machine-readable
form.
● And then, transmit the converted data into the
main memory of the computer. The sole
purpose is to connect the user and the computer.
In addition, this creates easy communication
between them.
● Central Processing Unit or the CPU, is the brain of
the computer. It works the same way a human brain
works. As the brain controls all human activities, the
CPU too controls all tasks.
● Moreover, the CPU conducts all the arithmetical and
logical operations in the computer.
The Arithmetic Logic Unit is made of two terms, arithmetic and logic.
There are two major functions that this unit performs.
1. Data inserted through the input unit into the primary memory.
Performs the basic arithmetical operation on it. Like addition,
subtraction, multiplication, and division. It performs all sorts of
calculations required on the data. Then sends back data to the
storage.
2. The unit is also responsible for performing logical operations
like, AND, OR, Equal to, Less than, etc. In addition to this it
conducts merging, sorting, and selection of the given data.
The control unit as the name suggests is the controller of all the
activities/tasks and operations. All this is performed inside the computer.
The memory unit sends a set of instructions to the control unit. Then the
control unit in turn converts those instructions. After that these
instructions are converted to control signals.
There are two types of computer memory-
1. Primary memory – This type of memory cannot store a vast
amount of data. Therefore, it is only used to store recent data.
The data stored in this is temporary. It can get erased once the
power is switched off. Therefore, is also called temporary
memory or the main memory.
2. Secondary memory – As explained above, the primary memory
stores temporary data. Thus it cannot be accessed in the future.
For permanent storage purposes, secondary memory is used.
The output unit displays the data either in the form of a soft copy or
hard copy. The printer is for the hard copy. The monitor is for the
display. The output unit accepts the data in binary form from the
computer. It then converts it into a readable form for the user.
C= 5/9 * (F-32)
Thank you.

More Related Content

What's hot

Operating systems By Awais
Operating systems By AwaisOperating systems By Awais
Operating systems By AwaisAwaisch3
 
Computer Worksheet Class 8 with answers
Computer Worksheet Class 8 with answersComputer Worksheet Class 8 with answers
Computer Worksheet Class 8 with answersAlithea Barbosa
 
Computer System
Computer SystemComputer System
Computer Systemhajjaz
 
History of Computer Programming Languages.pptx
History of Computer Programming Languages.pptxHistory of Computer Programming Languages.pptx
History of Computer Programming Languages.pptxAliAbbas906043
 
कंप्यूटर की पीढ़ियाँ
कंप्यूटर की पीढ़ियाँ कंप्यूटर की पीढ़ियाँ
कंप्यूटर की पीढ़ियाँ Dr. Amit Kumar Jha
 
Introduction To Computer Systems
Introduction To Computer SystemsIntroduction To Computer Systems
Introduction To Computer SystemsNaheed Azam
 
Introduction to programming
Introduction to programmingIntroduction to programming
Introduction to programmingNeeru Mittal
 
class One computer worksheet
class  One computer worksheetclass  One computer worksheet
class One computer worksheetFaB6 Design
 
What is Coding
What is CodingWhat is Coding
What is CodingRoboGarden
 
Hardware software & firmware
Hardware software &  firmwareHardware software &  firmware
Hardware software & firmwareNafizul Islam
 
6 multiprogramming & time sharing
6 multiprogramming & time sharing6 multiprogramming & time sharing
6 multiprogramming & time sharingmyrajendra
 
The Internet and the World Wide Web [IGCSE] [WWW].pptx
The Internet and the World Wide Web [IGCSE] [WWW].pptxThe Internet and the World Wide Web [IGCSE] [WWW].pptx
The Internet and the World Wide Web [IGCSE] [WWW].pptxEMMANUELOWOLABI8
 
Components of computer and organization
Components of computer and organizationComponents of computer and organization
Components of computer and organizationUniversity of Potsdam
 
Operating system Concepts
Operating system Concepts Operating system Concepts
Operating system Concepts RANVIJAY GAUR
 

What's hot (20)

Operating systems By Awais
Operating systems By AwaisOperating systems By Awais
Operating systems By Awais
 
Operating Systems
Operating SystemsOperating Systems
Operating Systems
 
Computer Worksheet Class 8 with answers
Computer Worksheet Class 8 with answersComputer Worksheet Class 8 with answers
Computer Worksheet Class 8 with answers
 
Computer System
Computer SystemComputer System
Computer System
 
Process scheduling
Process schedulingProcess scheduling
Process scheduling
 
History of Computer Programming Languages.pptx
History of Computer Programming Languages.pptxHistory of Computer Programming Languages.pptx
History of Computer Programming Languages.pptx
 
कंप्यूटर की पीढ़ियाँ
कंप्यूटर की पीढ़ियाँ कंप्यूटर की पीढ़ियाँ
कंप्यूटर की पीढ़ियाँ
 
Introduction To Computer Systems
Introduction To Computer SystemsIntroduction To Computer Systems
Introduction To Computer Systems
 
Keyboard
KeyboardKeyboard
Keyboard
 
Introduction to programming
Introduction to programmingIntroduction to programming
Introduction to programming
 
Gray Code.pptx
Gray Code.pptxGray Code.pptx
Gray Code.pptx
 
class One computer worksheet
class  One computer worksheetclass  One computer worksheet
class One computer worksheet
 
What is Coding
What is CodingWhat is Coding
What is Coding
 
Hardware software & firmware
Hardware software &  firmwareHardware software &  firmware
Hardware software & firmware
 
Presentation on operating system
 Presentation on operating system Presentation on operating system
Presentation on operating system
 
6 multiprogramming & time sharing
6 multiprogramming & time sharing6 multiprogramming & time sharing
6 multiprogramming & time sharing
 
The Internet and the World Wide Web [IGCSE] [WWW].pptx
The Internet and the World Wide Web [IGCSE] [WWW].pptxThe Internet and the World Wide Web [IGCSE] [WWW].pptx
The Internet and the World Wide Web [IGCSE] [WWW].pptx
 
Components of computer and organization
Components of computer and organizationComponents of computer and organization
Components of computer and organization
 
operating system
operating systemoperating system
operating system
 
Operating system Concepts
Operating system Concepts Operating system Concepts
Operating system Concepts
 

Similar to PsudoCode.pptx

Unit 1 python (2021 r)
Unit 1 python (2021 r)Unit 1 python (2021 r)
Unit 1 python (2021 r)praveena p
 
Introduction to Computer UNIT 1 notes.pdf
Introduction to Computer UNIT 1 notes.pdfIntroduction to Computer UNIT 1 notes.pdf
Introduction to Computer UNIT 1 notes.pdfshubhangisonawane6
 
Introduction to data structures
Introduction to data structuresIntroduction to data structures
Introduction to data structuresDhanashriAmbre
 
Introduction to computers MRS. SOWMYA JYOTHI
Introduction to computers MRS. SOWMYA JYOTHIIntroduction to computers MRS. SOWMYA JYOTHI
Introduction to computers MRS. SOWMYA JYOTHISowmya Jyothi
 
Chapter 2(1)
Chapter 2(1)Chapter 2(1)
Chapter 2(1)TejaswiB4
 
Ia syllabus Topic computer Related
Ia syllabus Topic computer RelatedIa syllabus Topic computer Related
Ia syllabus Topic computer RelatedOnline Job Study
 
Algorithm types performance steps working
Algorithm types performance steps workingAlgorithm types performance steps working
Algorithm types performance steps workingSaurabh846965
 
Algorithm for computational problematic sit
Algorithm for computational problematic sitAlgorithm for computational problematic sit
Algorithm for computational problematic sitSaurabh846965
 
Chapter 1-Microprocessors, Microcomputers, and Assembly Language
Chapter 1-Microprocessors, Microcomputers, and Assembly LanguageChapter 1-Microprocessors, Microcomputers, and Assembly Language
Chapter 1-Microprocessors, Microcomputers, and Assembly Languagecmkandemir
 
Computer Fundamental.pdf
Computer Fundamental.pdfComputer Fundamental.pdf
Computer Fundamental.pdfDagneDegefu
 
Program concep sequential statements
Program concep sequential statementsProgram concep sequential statements
Program concep sequential statementsankurkhanna
 
Computer science basics for nonit students
Computer science basics for nonit studentsComputer science basics for nonit students
Computer science basics for nonit studentsSrikanth KS
 
3 - Thermometer.pptx thermometer thermometer thermometer
3 - Thermometer.pptx thermometer thermometer thermometer3 - Thermometer.pptx thermometer thermometer thermometer
3 - Thermometer.pptx thermometer thermometer thermometeraustcornish143
 
ProgFund_Lecture7_Programming_Algorithm.pdf
ProgFund_Lecture7_Programming_Algorithm.pdfProgFund_Lecture7_Programming_Algorithm.pdf
ProgFund_Lecture7_Programming_Algorithm.pdflailoesakhan
 
Data Structure Notes unit 1.docx
Data Structure Notes unit 1.docxData Structure Notes unit 1.docx
Data Structure Notes unit 1.docxkp370932
 
Computer Operations & Packages
Computer Operations & PackagesComputer Operations & Packages
Computer Operations & PackagesMakaha Rutendo
 

Similar to PsudoCode.pptx (20)

Introduction.pptx
Introduction.pptxIntroduction.pptx
Introduction.pptx
 
C++ good tutorial
C++ good tutorialC++ good tutorial
C++ good tutorial
 
Unit 1 python (2021 r)
Unit 1 python (2021 r)Unit 1 python (2021 r)
Unit 1 python (2021 r)
 
Introduction to Computer UNIT 1 notes.pdf
Introduction to Computer UNIT 1 notes.pdfIntroduction to Computer UNIT 1 notes.pdf
Introduction to Computer UNIT 1 notes.pdf
 
Introduction to data structures
Introduction to data structuresIntroduction to data structures
Introduction to data structures
 
Introduction to computers MRS. SOWMYA JYOTHI
Introduction to computers MRS. SOWMYA JYOTHIIntroduction to computers MRS. SOWMYA JYOTHI
Introduction to computers MRS. SOWMYA JYOTHI
 
CC-112-Lec.1.ppsx
CC-112-Lec.1.ppsxCC-112-Lec.1.ppsx
CC-112-Lec.1.ppsx
 
Chapter 2(1)
Chapter 2(1)Chapter 2(1)
Chapter 2(1)
 
Ia syllabus Topic computer Related
Ia syllabus Topic computer RelatedIa syllabus Topic computer Related
Ia syllabus Topic computer Related
 
Algorithm types performance steps working
Algorithm types performance steps workingAlgorithm types performance steps working
Algorithm types performance steps working
 
Algorithm for computational problematic sit
Algorithm for computational problematic sitAlgorithm for computational problematic sit
Algorithm for computational problematic sit
 
UNIT-1.pptx
UNIT-1.pptxUNIT-1.pptx
UNIT-1.pptx
 
Chapter 1-Microprocessors, Microcomputers, and Assembly Language
Chapter 1-Microprocessors, Microcomputers, and Assembly LanguageChapter 1-Microprocessors, Microcomputers, and Assembly Language
Chapter 1-Microprocessors, Microcomputers, and Assembly Language
 
Computer Fundamental.pdf
Computer Fundamental.pdfComputer Fundamental.pdf
Computer Fundamental.pdf
 
Program concep sequential statements
Program concep sequential statementsProgram concep sequential statements
Program concep sequential statements
 
Computer science basics for nonit students
Computer science basics for nonit studentsComputer science basics for nonit students
Computer science basics for nonit students
 
3 - Thermometer.pptx thermometer thermometer thermometer
3 - Thermometer.pptx thermometer thermometer thermometer3 - Thermometer.pptx thermometer thermometer thermometer
3 - Thermometer.pptx thermometer thermometer thermometer
 
ProgFund_Lecture7_Programming_Algorithm.pdf
ProgFund_Lecture7_Programming_Algorithm.pdfProgFund_Lecture7_Programming_Algorithm.pdf
ProgFund_Lecture7_Programming_Algorithm.pdf
 
Data Structure Notes unit 1.docx
Data Structure Notes unit 1.docxData Structure Notes unit 1.docx
Data Structure Notes unit 1.docx
 
Computer Operations & Packages
Computer Operations & PackagesComputer Operations & Packages
Computer Operations & Packages
 

More from Shehrevar Davierwala (20)

Introduction_Swift
Introduction_SwiftIntroduction_Swift
Introduction_Swift
 
Java Script (Module 1).pptx
Java Script (Module 1).pptxJava Script (Module 1).pptx
Java Script (Module 1).pptx
 
Website in Clicks Day 2
Website in Clicks Day 2Website in Clicks Day 2
Website in Clicks Day 2
 
Develop Website in Clicks
Develop Website in ClicksDevelop Website in Clicks
Develop Website in Clicks
 
Build Virtual Assistant Using AI
Build Virtual Assistant Using AI Build Virtual Assistant Using AI
Build Virtual Assistant Using AI
 
Build brand reputation using facebook
Build brand reputation using facebookBuild brand reputation using facebook
Build brand reputation using facebook
 
Digital Marketing Session 2
Digital Marketing Session 2Digital Marketing Session 2
Digital Marketing Session 2
 
Learn Digital Marketing : 0 to Hero Day 1
Learn Digital Marketing :  0 to Hero Day 1 Learn Digital Marketing :  0 to Hero Day 1
Learn Digital Marketing : 0 to Hero Day 1
 
Standard template
Standard templateStandard template
Standard template
 
Digital Marketing for Sustainable Business - Afghan Perspective
Digital Marketing for Sustainable Business - Afghan Perspective  Digital Marketing for Sustainable Business - Afghan Perspective
Digital Marketing for Sustainable Business - Afghan Perspective
 
Developing stunning website in clicks - 2
Developing stunning website in clicks - 2Developing stunning website in clicks - 2
Developing stunning website in clicks - 2
 
Developing stunning website in clicks
Developing stunning website in clicksDeveloping stunning website in clicks
Developing stunning website in clicks
 
Google forms for data analysis
Google forms for data analysisGoogle forms for data analysis
Google forms for data analysis
 
Webdesign session1
Webdesign session1Webdesign session1
Webdesign session1
 
Tech talk webtech
Tech talk webtechTech talk webtech
Tech talk webtech
 
Tech talk php_cms
Tech talk php_cmsTech talk php_cms
Tech talk php_cms
 
Ph pbasics
Ph pbasicsPh pbasics
Ph pbasics
 
Php mysql
Php mysqlPhp mysql
Php mysql
 
Java operators
Java operatorsJava operators
Java operators
 
Basic
BasicBasic
Basic
 

Recently uploaded

Hierarchy of management that covers different levels of management
Hierarchy of management that covers different levels of managementHierarchy of management that covers different levels of management
Hierarchy of management that covers different levels of managementmkooblal
 
Employee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxEmployee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxNirmalaLoungPoorunde1
 
Proudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptxProudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptxthorishapillay1
 
HỌC TỐT TIẾNG ANH 11 THEO CHƯƠNG TRÌNH GLOBAL SUCCESS ĐÁP ÁN CHI TIẾT - CẢ NĂ...
HỌC TỐT TIẾNG ANH 11 THEO CHƯƠNG TRÌNH GLOBAL SUCCESS ĐÁP ÁN CHI TIẾT - CẢ NĂ...HỌC TỐT TIẾNG ANH 11 THEO CHƯƠNG TRÌNH GLOBAL SUCCESS ĐÁP ÁN CHI TIẾT - CẢ NĂ...
HỌC TỐT TIẾNG ANH 11 THEO CHƯƠNG TRÌNH GLOBAL SUCCESS ĐÁP ÁN CHI TIẾT - CẢ NĂ...Nguyen Thanh Tu Collection
 
Difference Between Search & Browse Methods in Odoo 17
Difference Between Search & Browse Methods in Odoo 17Difference Between Search & Browse Methods in Odoo 17
Difference Between Search & Browse Methods in Odoo 17Celine George
 
Atmosphere science 7 quarter 4 .........
Atmosphere science 7 quarter 4 .........Atmosphere science 7 quarter 4 .........
Atmosphere science 7 quarter 4 .........LeaCamillePacle
 
Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdf
Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdfFraming an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdf
Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdfUjwalaBharambe
 
How to do quick user assign in kanban in Odoo 17 ERP
How to do quick user assign in kanban in Odoo 17 ERPHow to do quick user assign in kanban in Odoo 17 ERP
How to do quick user assign in kanban in Odoo 17 ERPCeline George
 
ROOT CAUSE ANALYSIS PowerPoint Presentation
ROOT CAUSE ANALYSIS PowerPoint PresentationROOT CAUSE ANALYSIS PowerPoint Presentation
ROOT CAUSE ANALYSIS PowerPoint PresentationAadityaSharma884161
 
Field Attribute Index Feature in Odoo 17
Field Attribute Index Feature in Odoo 17Field Attribute Index Feature in Odoo 17
Field Attribute Index Feature in Odoo 17Celine George
 
What is Model Inheritance in Odoo 17 ERP
What is Model Inheritance in Odoo 17 ERPWhat is Model Inheritance in Odoo 17 ERP
What is Model Inheritance in Odoo 17 ERPCeline George
 
How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17Celine George
 
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptx
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptxMULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptx
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptxAnupkumar Sharma
 
Types of Journalistic Writing Grade 8.pptx
Types of Journalistic Writing Grade 8.pptxTypes of Journalistic Writing Grade 8.pptx
Types of Journalistic Writing Grade 8.pptxEyham Joco
 
Romantic Opera MUSIC FOR GRADE NINE pptx
Romantic Opera MUSIC FOR GRADE NINE pptxRomantic Opera MUSIC FOR GRADE NINE pptx
Romantic Opera MUSIC FOR GRADE NINE pptxsqpmdrvczh
 
Influencing policy (training slides from Fast Track Impact)
Influencing policy (training slides from Fast Track Impact)Influencing policy (training slides from Fast Track Impact)
Influencing policy (training slides from Fast Track Impact)Mark Reed
 
Grade 9 Q4-MELC1-Active and Passive Voice.pptx
Grade 9 Q4-MELC1-Active and Passive Voice.pptxGrade 9 Q4-MELC1-Active and Passive Voice.pptx
Grade 9 Q4-MELC1-Active and Passive Voice.pptxChelloAnnAsuncion2
 
DATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginnersDATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginnersSabitha Banu
 
Alper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentAlper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentInMediaRes1
 

Recently uploaded (20)

Hierarchy of management that covers different levels of management
Hierarchy of management that covers different levels of managementHierarchy of management that covers different levels of management
Hierarchy of management that covers different levels of management
 
Employee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxEmployee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptx
 
Proudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptxProudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptx
 
HỌC TỐT TIẾNG ANH 11 THEO CHƯƠNG TRÌNH GLOBAL SUCCESS ĐÁP ÁN CHI TIẾT - CẢ NĂ...
HỌC TỐT TIẾNG ANH 11 THEO CHƯƠNG TRÌNH GLOBAL SUCCESS ĐÁP ÁN CHI TIẾT - CẢ NĂ...HỌC TỐT TIẾNG ANH 11 THEO CHƯƠNG TRÌNH GLOBAL SUCCESS ĐÁP ÁN CHI TIẾT - CẢ NĂ...
HỌC TỐT TIẾNG ANH 11 THEO CHƯƠNG TRÌNH GLOBAL SUCCESS ĐÁP ÁN CHI TIẾT - CẢ NĂ...
 
Difference Between Search & Browse Methods in Odoo 17
Difference Between Search & Browse Methods in Odoo 17Difference Between Search & Browse Methods in Odoo 17
Difference Between Search & Browse Methods in Odoo 17
 
Atmosphere science 7 quarter 4 .........
Atmosphere science 7 quarter 4 .........Atmosphere science 7 quarter 4 .........
Atmosphere science 7 quarter 4 .........
 
Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdf
Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdfFraming an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdf
Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdf
 
How to do quick user assign in kanban in Odoo 17 ERP
How to do quick user assign in kanban in Odoo 17 ERPHow to do quick user assign in kanban in Odoo 17 ERP
How to do quick user assign in kanban in Odoo 17 ERP
 
ROOT CAUSE ANALYSIS PowerPoint Presentation
ROOT CAUSE ANALYSIS PowerPoint PresentationROOT CAUSE ANALYSIS PowerPoint Presentation
ROOT CAUSE ANALYSIS PowerPoint Presentation
 
Field Attribute Index Feature in Odoo 17
Field Attribute Index Feature in Odoo 17Field Attribute Index Feature in Odoo 17
Field Attribute Index Feature in Odoo 17
 
What is Model Inheritance in Odoo 17 ERP
What is Model Inheritance in Odoo 17 ERPWhat is Model Inheritance in Odoo 17 ERP
What is Model Inheritance in Odoo 17 ERP
 
Model Call Girl in Bikash Puri Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Bikash Puri  Delhi reach out to us at 🔝9953056974🔝Model Call Girl in Bikash Puri  Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Bikash Puri Delhi reach out to us at 🔝9953056974🔝
 
How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17
 
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptx
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptxMULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptx
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptx
 
Types of Journalistic Writing Grade 8.pptx
Types of Journalistic Writing Grade 8.pptxTypes of Journalistic Writing Grade 8.pptx
Types of Journalistic Writing Grade 8.pptx
 
Romantic Opera MUSIC FOR GRADE NINE pptx
Romantic Opera MUSIC FOR GRADE NINE pptxRomantic Opera MUSIC FOR GRADE NINE pptx
Romantic Opera MUSIC FOR GRADE NINE pptx
 
Influencing policy (training slides from Fast Track Impact)
Influencing policy (training slides from Fast Track Impact)Influencing policy (training slides from Fast Track Impact)
Influencing policy (training slides from Fast Track Impact)
 
Grade 9 Q4-MELC1-Active and Passive Voice.pptx
Grade 9 Q4-MELC1-Active and Passive Voice.pptxGrade 9 Q4-MELC1-Active and Passive Voice.pptx
Grade 9 Q4-MELC1-Active and Passive Voice.pptx
 
DATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginnersDATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginners
 
Alper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentAlper Gobel In Media Res Media Component
Alper Gobel In Media Res Media Component
 

PsudoCode.pptx

  • 1. Logic Building Techniques and Practices Section 2
  • 3. Activity 1. One person hides a piece of “treasure” (this could be anything!) in an indoor or outdoor space. 2. Next, the treasure hider writes out instructions explaining how to find the hidden object. The instructions need to be very clear so the finder knows exactly what to do – otherwise, they won’t get to the treasure! Example: ○ Take 10 steps STRAIGHT ○ Turn RIGHT and take 5 big hops ○ Turn LEFT and crawl 8 times ○ Dig 2 inches down to find the treasure! 3. Once the instructions are written, the finder follows them exactly. 4. If instructions aren’t clear enough, the hider may need to find the bug and fix it so the finder can successfully reach the treasure. 5. Switch places when finished.
  • 4. Merits of Algorithm ● It is easy to understand. ● An algorithm is a step-wise representation of a solution to a given problem. ● In Algorithm the problem is broken down into smaller pieces or steps hence, it is easier for the programmer to convert it into an actual program.
  • 5. Demerits of Algorithm ● Writing an algorithm takes a long time so it is time- consuming. ● Understanding complex logic through algorithms can be very difficult. ● Branching and Looping statements are difficult to show in Algorithms
  • 7. What is a process ? The instance of a computer program that is being executed by one or many threads. A thread is the smallest unit of processing
  • 8. Conditional / Decision Statements ● Conditional statements help you to make a decision based on certain conditions. ● Conditional statements always have an if part, which tells the what to do when the condition is true. ● Conditional statements also usually have an else part, which tells the what to do when the condition is false.
  • 10. Practice - Algorithm to check even or odd number ● If we divide number by 2 and multiply it by 2 if the number is same then the number (2*N) ● else the number is odd (2*n+1) Step 1: Start Step 2: Read a number to N Step 3: R= N/2 store the remainder(R). Step 4: If R = O Then go to Step 6 Step 5: Print “N is odd” go to step 7 Step 6: Print “N is even” Step 7: Stop
  • 12. Algorithm for angry bird - DIV C Step1 : https://studio.code.org/join Step 2: type in their section code: HQYKXB Step3: fill in the details Step 4: Follow video instructions carefully and complete the session Scan for Certificate
  • 13. Algorithm for angry bird - DIV D Step1 : https://studio.code.org/join Step 2: type in their section code: KWJWWJ Step3: fill in the details Step 4: Follow video instructions carefully and complete the session
  • 14. Loops (Iteration) 0 1 0 2 0 3 a loop is a sequence of instruction s that is continually repeated until a certain condition is reached
  • 15. Pseudo code ● It is a methodology that allows the programmer to represent the implementation of an algorithm. ● Pseudo code, as the name suggests, is a false code or a representation of code which can be understood by even a layman with some school level programming knowledge.
  • 16. Example: if "1" print response "I am happy" if "2" print response "You are sad"
  • 17. Advantages of Pseudocode ● Improves the readability of any approach. It’s one of the best approaches to start implementation of an algorithm. ● Acts as a bridge between the program and the algorithm or flowchart. Also works as a rough documentation, so the program of one developer can be understood easily when a pseudo code is written out. In industries, the approach of documentation is essential. And that’s where a pseudo-code proves vital. ● The main goal of a pseudo code is to explain what exactly each line of a program should do, hence making the code construction phase easier for the
  • 18. The 3 major functions of the input unit are- ● Take the data to be processed by the user. ● Convert the given data into machine-readable form. ● And then, transmit the converted data into the main memory of the computer. The sole purpose is to connect the user and the computer. In addition, this creates easy communication between them.
  • 19. ● Central Processing Unit or the CPU, is the brain of the computer. It works the same way a human brain works. As the brain controls all human activities, the CPU too controls all tasks. ● Moreover, the CPU conducts all the arithmetical and logical operations in the computer.
  • 20. The Arithmetic Logic Unit is made of two terms, arithmetic and logic. There are two major functions that this unit performs. 1. Data inserted through the input unit into the primary memory. Performs the basic arithmetical operation on it. Like addition, subtraction, multiplication, and division. It performs all sorts of calculations required on the data. Then sends back data to the storage. 2. The unit is also responsible for performing logical operations like, AND, OR, Equal to, Less than, etc. In addition to this it conducts merging, sorting, and selection of the given data.
  • 21. The control unit as the name suggests is the controller of all the activities/tasks and operations. All this is performed inside the computer. The memory unit sends a set of instructions to the control unit. Then the control unit in turn converts those instructions. After that these instructions are converted to control signals.
  • 22. There are two types of computer memory- 1. Primary memory – This type of memory cannot store a vast amount of data. Therefore, it is only used to store recent data. The data stored in this is temporary. It can get erased once the power is switched off. Therefore, is also called temporary memory or the main memory. 2. Secondary memory – As explained above, the primary memory stores temporary data. Thus it cannot be accessed in the future. For permanent storage purposes, secondary memory is used.
  • 23. The output unit displays the data either in the form of a soft copy or hard copy. The printer is for the hard copy. The monitor is for the display. The output unit accepts the data in binary form from the computer. It then converts it into a readable form for the user.
  • 24. C= 5/9 * (F-32)