SlideShare une entreprise Scribd logo
1  sur  20
Algorithm
What is an algorithm?
“A set of rules to be
followed in problem
solving operations.”
or “A Recipe”
Input   Algorithm   Output
Input   Algorithm               Output
        “A set of rules to be
        followed in problem
        solving operations.”
Input                Algorithm               Output
•   2 slices bread
                           “A set of rules to be
•   1 tbsp peanut butter   followed in problem
•   2 tsp strawberry jam   solving operations.”
Input                Algorithm               Output
•   2 slices bread
                           “A set of rules to be
•   1 tbsp peanut butter   followed in problem
•   2 tsp strawberry jam   solving operations.”
Input                Algorithm   Output
•   2 slices bread

•   1 tbsp peanut butter

•   2 tsp strawberry jam
Selena & Michelle’s
  PBJ algorithm
How many steps do you think it will
            take?
There’s more than
 one way to do it.
"""
(C) Gerold Penz)
Python can be simple, too :-)
"""

for quant in range(99, 0, -1):
  if quant > 1:
    print quant, "bottles of beer on the wall,", quant, "bottles of beer."
    if quant > 2:
      suffix = str(quant - 1) + " bottles of beer on the wall."
    else:
      suffix = "1 bottle of beer on the wall."
  elif quant == 1:
    print "1 bottle of beer on the wall, 1 bottle of beer."
    suffix = "no more beer on the wall!"
  print "Take one down, pass it around,", suffix
  print "--"
# (c) Barbara Shaurette

def bottles():
 for i in reversed(range(100)):
  if i > 0:
    b = "bottles"
    if i == 1: b = "bottle"
    print i, b, "of beer on the wall,", 
      i, b, "of beer"
    print "Take one down, pass it around,", 
      i-1, "bottles of beer on the wallnr"

bottles()
Your algorithms
Example: Get from
the airport to home.
“The taxi algorithm”

• Go to the taxi stand.
• Get in a taxi.
• Give the driver my address.
“The call-me
         algorithm”

• When your plane arrives, call my cell
  phone.
• Meet me outside baggage claim.
“The rent-a-car
       algorithm”

• Take the shuttle to the rental car place.
• Rent a car.
• Follow the directions to get to my
  house.
“The bus algorithm”

• Outside baggage claim, catch bus
  number 70.
• Transfer to bus 14 on Main Street.
• Get off on Elm street.
• Walk two blocks north to my house.
All get you to where
  you need to go.

Contenu connexe

Tendances

Algorithms and flowcharts
Algorithms and flowchartsAlgorithms and flowcharts
Algorithms and flowchartsSamuel Igbanogu
 
Job Opportunities for a Computer Science Student
Job Opportunities for a Computer Science StudentJob Opportunities for a Computer Science Student
Job Opportunities for a Computer Science StudentSyed Areeb Jafri
 
Fundamental Programming Lect 2
Fundamental Programming Lect 2Fundamental Programming Lect 2
Fundamental Programming Lect 2Namrah Erum
 
What is an algorithm?
What is an algorithm?What is an algorithm?
What is an algorithm?Angela DeHart
 
Image Processing and Computer Vision
Image Processing and Computer VisionImage Processing and Computer Vision
Image Processing and Computer VisionSilicon Mentor
 
Lecture 01 Introduction to Software Engineering
Lecture 01 Introduction to Software EngineeringLecture 01 Introduction to Software Engineering
Lecture 01 Introduction to Software EngineeringAchmad Solichin
 
What Is Strong (General) AI? Here Are 9 Practical Examples
What Is Strong (General) AI? Here Are 9 Practical Examples What Is Strong (General) AI? Here Are 9 Practical Examples
What Is Strong (General) AI? Here Are 9 Practical Examples Bernard Marr
 
Types of artificial intelligence
Types of artificial intelligenceTypes of artificial intelligence
Types of artificial intelligenceHoneyChintal
 
AN INTRODUCTION TO EMERGING TECHNOLOGY
AN INTRODUCTION TO EMERGING TECHNOLOGYAN INTRODUCTION TO EMERGING TECHNOLOGY
AN INTRODUCTION TO EMERGING TECHNOLOGYVijay R. Joshi
 
From Narrow AI to Artificial General Intelligence (AGI)
From Narrow AI to Artificial General Intelligence (AGI)From Narrow AI to Artificial General Intelligence (AGI)
From Narrow AI to Artificial General Intelligence (AGI)Helgi Páll Helgason, PhD
 
Globalization issues in project management
Globalization issues in project managementGlobalization issues in project management
Globalization issues in project managementMenakapriyaM
 
Algorithm analysis (All in one)
Algorithm analysis (All in one)Algorithm analysis (All in one)
Algorithm analysis (All in one)jehan1987
 

Tendances (20)

Emerging Technologies in IT
Emerging Technologies in ITEmerging Technologies in IT
Emerging Technologies in IT
 
Algorithms and flowcharts
Algorithms and flowchartsAlgorithms and flowcharts
Algorithms and flowcharts
 
Job Opportunities for a Computer Science Student
Job Opportunities for a Computer Science StudentJob Opportunities for a Computer Science Student
Job Opportunities for a Computer Science Student
 
Programming
ProgrammingProgramming
Programming
 
Introduction to algorithms
Introduction to algorithmsIntroduction to algorithms
Introduction to algorithms
 
Fundamental Programming Lect 2
Fundamental Programming Lect 2Fundamental Programming Lect 2
Fundamental Programming Lect 2
 
Requirements engineering
Requirements engineeringRequirements engineering
Requirements engineering
 
PhD Thesis Defense Presentation
PhD Thesis Defense PresentationPhD Thesis Defense Presentation
PhD Thesis Defense Presentation
 
What is an algorithm?
What is an algorithm?What is an algorithm?
What is an algorithm?
 
Artificial intelligence
Artificial intelligenceArtificial intelligence
Artificial intelligence
 
Image Processing and Computer Vision
Image Processing and Computer VisionImage Processing and Computer Vision
Image Processing and Computer Vision
 
IEEE 12207
IEEE 12207IEEE 12207
IEEE 12207
 
Lecture 01 Introduction to Software Engineering
Lecture 01 Introduction to Software EngineeringLecture 01 Introduction to Software Engineering
Lecture 01 Introduction to Software Engineering
 
What Is Strong (General) AI? Here Are 9 Practical Examples
What Is Strong (General) AI? Here Are 9 Practical Examples What Is Strong (General) AI? Here Are 9 Practical Examples
What Is Strong (General) AI? Here Are 9 Practical Examples
 
Types of artificial intelligence
Types of artificial intelligenceTypes of artificial intelligence
Types of artificial intelligence
 
AN INTRODUCTION TO EMERGING TECHNOLOGY
AN INTRODUCTION TO EMERGING TECHNOLOGYAN INTRODUCTION TO EMERGING TECHNOLOGY
AN INTRODUCTION TO EMERGING TECHNOLOGY
 
From Narrow AI to Artificial General Intelligence (AGI)
From Narrow AI to Artificial General Intelligence (AGI)From Narrow AI to Artificial General Intelligence (AGI)
From Narrow AI to Artificial General Intelligence (AGI)
 
Globalization issues in project management
Globalization issues in project managementGlobalization issues in project management
Globalization issues in project management
 
Reqmt_Engn.ppt
Reqmt_Engn.pptReqmt_Engn.ppt
Reqmt_Engn.ppt
 
Algorithm analysis (All in one)
Algorithm analysis (All in one)Algorithm analysis (All in one)
Algorithm analysis (All in one)
 

En vedette

Introduction to Recipes for Agile Governance in the Enterprise (RAGE)
Introduction to Recipes for Agile Governance in the Enterprise (RAGE)Introduction to Recipes for Agile Governance in the Enterprise (RAGE)
Introduction to Recipes for Agile Governance in the Enterprise (RAGE)Cprime
 
Writing Chapters 1, 2, 3 of the Capstone Project Proposal Manuscript
Writing Chapters 1, 2, 3 of the Capstone Project Proposal ManuscriptWriting Chapters 1, 2, 3 of the Capstone Project Proposal Manuscript
Writing Chapters 1, 2, 3 of the Capstone Project Proposal ManuscriptSheryl Satorre
 
O que aconteceu com os mundos virtuais no ensino?
O que aconteceu com os mundos virtuais no ensino?O que aconteceu com os mundos virtuais no ensino?
O que aconteceu com os mundos virtuais no ensino?Neli Maria Mengalli
 
圖說人生哲理
圖說人生哲理圖說人生哲理
圖說人生哲理nonnon
 
Spring 3 - An Introduction
Spring 3 - An IntroductionSpring 3 - An Introduction
Spring 3 - An IntroductionThorsten Kamann
 
Class Project Pxgt 6110
Class Project Pxgt 6110Class Project Pxgt 6110
Class Project Pxgt 6110asmajuhan
 
你的桶子有多滿
你的桶子有多滿你的桶子有多滿
你的桶子有多滿nonnon
 
Baker Wedding Slideshow Review
Baker Wedding Slideshow ReviewBaker Wedding Slideshow Review
Baker Wedding Slideshow Reviewmattwjohnson
 
Even Start Flipbook
Even Start FlipbookEven Start Flipbook
Even Start Flipbookkkibbey
 
Data Mining Protein Structures' Topological Properties to Enhance Contact Ma...
Data Mining Protein Structures' Topological Properties  to Enhance Contact Ma...Data Mining Protein Structures' Topological Properties  to Enhance Contact Ma...
Data Mining Protein Structures' Topological Properties to Enhance Contact Ma...jaumebp
 
Lorelle at WordCamp 2008 - 260 Ways to Break WordPress
Lorelle at WordCamp 2008 - 260 Ways to Break WordPressLorelle at WordCamp 2008 - 260 Ways to Break WordPress
Lorelle at WordCamp 2008 - 260 Ways to Break WordPressLorelle VanFossen
 
La3 Computer Network
La3 Computer NetworkLa3 Computer Network
La3 Computer NetworkCma Mohd
 
Johannes Lars
Johannes LarsJohannes Lars
Johannes Larseka
 

En vedette (20)

Making Software Communities
Making Software CommunitiesMaking Software Communities
Making Software Communities
 
Introduction to Recipes for Agile Governance in the Enterprise (RAGE)
Introduction to Recipes for Agile Governance in the Enterprise (RAGE)Introduction to Recipes for Agile Governance in the Enterprise (RAGE)
Introduction to Recipes for Agile Governance in the Enterprise (RAGE)
 
Writing Chapters 1, 2, 3 of the Capstone Project Proposal Manuscript
Writing Chapters 1, 2, 3 of the Capstone Project Proposal ManuscriptWriting Chapters 1, 2, 3 of the Capstone Project Proposal Manuscript
Writing Chapters 1, 2, 3 of the Capstone Project Proposal Manuscript
 
Flex et Php Afup
Flex et Php AfupFlex et Php Afup
Flex et Php Afup
 
O que aconteceu com os mundos virtuais no ensino?
O que aconteceu com os mundos virtuais no ensino?O que aconteceu com os mundos virtuais no ensino?
O que aconteceu com os mundos virtuais no ensino?
 
Ch01
Ch01Ch01
Ch01
 
圖說人生哲理
圖說人生哲理圖說人生哲理
圖說人生哲理
 
Spring 3 - An Introduction
Spring 3 - An IntroductionSpring 3 - An Introduction
Spring 3 - An Introduction
 
Class Project Pxgt 6110
Class Project Pxgt 6110Class Project Pxgt 6110
Class Project Pxgt 6110
 
你的桶子有多滿
你的桶子有多滿你的桶子有多滿
你的桶子有多滿
 
Baker Wedding Slideshow Review
Baker Wedding Slideshow ReviewBaker Wedding Slideshow Review
Baker Wedding Slideshow Review
 
Even Start Flipbook
Even Start FlipbookEven Start Flipbook
Even Start Flipbook
 
Data Mining Protein Structures' Topological Properties to Enhance Contact Ma...
Data Mining Protein Structures' Topological Properties  to Enhance Contact Ma...Data Mining Protein Structures' Topological Properties  to Enhance Contact Ma...
Data Mining Protein Structures' Topological Properties to Enhance Contact Ma...
 
Lorelle at WordCamp 2008 - 260 Ways to Break WordPress
Lorelle at WordCamp 2008 - 260 Ways to Break WordPressLorelle at WordCamp 2008 - 260 Ways to Break WordPress
Lorelle at WordCamp 2008 - 260 Ways to Break WordPress
 
4 T
4  T4  T
4 T
 
6. open innov conclusions
6. open innov conclusions6. open innov conclusions
6. open innov conclusions
 
La3 Computer Network
La3 Computer NetworkLa3 Computer Network
La3 Computer Network
 
I M S Rubashkin
I M S RubashkinI M S Rubashkin
I M S Rubashkin
 
Johannes Lars
Johannes LarsJohannes Lars
Johannes Lars
 
Hide you file behind a picture
Hide you file behind a pictureHide you file behind a picture
Hide you file behind a picture
 

Plus de Selena Deckelmann

While we're here, let's fix computer science education
While we're here, let's fix computer science educationWhile we're here, let's fix computer science education
While we're here, let's fix computer science educationSelena Deckelmann
 
Mistakes were made - LCA 2012
Mistakes were made - LCA 2012Mistakes were made - LCA 2012
Mistakes were made - LCA 2012Selena Deckelmann
 
Postgres needs an aircraft carrier
Postgres needs an aircraft carrierPostgres needs an aircraft carrier
Postgres needs an aircraft carrierSelena Deckelmann
 
Harder, better, faster, stronger: PostgreSQL 9.1
Harder, better, faster, stronger: PostgreSQL 9.1Harder, better, faster, stronger: PostgreSQL 9.1
Harder, better, faster, stronger: PostgreSQL 9.1Selena Deckelmann
 
Letters from the open source trenches - Postgres community
Letters from the open source trenches - Postgres communityLetters from the open source trenches - Postgres community
Letters from the open source trenches - Postgres communitySelena Deckelmann
 
Own it: working with a changing open source community
Own it: working with a changing open source communityOwn it: working with a changing open source community
Own it: working with a changing open source communitySelena Deckelmann
 
Managing terabytes: When Postgres gets big
Managing terabytes: When Postgres gets bigManaging terabytes: When Postgres gets big
Managing terabytes: When Postgres gets bigSelena Deckelmann
 
Managing terabytes: When PostgreSQL gets big
Managing terabytes: When PostgreSQL gets bigManaging terabytes: When PostgreSQL gets big
Managing terabytes: When PostgreSQL gets bigSelena Deckelmann
 
How a bunch of normal people Used Technology To Repair a Rigged Election
How a bunch of normal people Used Technology To Repair a Rigged ElectionHow a bunch of normal people Used Technology To Repair a Rigged Election
How a bunch of normal people Used Technology To Repair a Rigged ElectionSelena Deckelmann
 
Open Source Bridge Opening Day
Open Source Bridge Opening DayOpen Source Bridge Opening Day
Open Source Bridge Opening DaySelena Deckelmann
 
What Assumptions Make: Filesystem I/O from a database perspective
What Assumptions Make: Filesystem I/O from a database perspectiveWhat Assumptions Make: Filesystem I/O from a database perspective
What Assumptions Make: Filesystem I/O from a database perspectiveSelena Deckelmann
 

Plus de Selena Deckelmann (20)

While we're here, let's fix computer science education
While we're here, let's fix computer science educationWhile we're here, let's fix computer science education
While we're here, let's fix computer science education
 
Hire the right way
Hire the right wayHire the right way
Hire the right way
 
Mistakes were made - LCA 2012
Mistakes were made - LCA 2012Mistakes were made - LCA 2012
Mistakes were made - LCA 2012
 
Pg92 HA, LCA 2012, Ballarat
Pg92 HA, LCA 2012, BallaratPg92 HA, LCA 2012, Ballarat
Pg92 HA, LCA 2012, Ballarat
 
Managing terabytes
Managing terabytesManaging terabytes
Managing terabytes
 
Mistakes were made
Mistakes were madeMistakes were made
Mistakes were made
 
Postgres needs an aircraft carrier
Postgres needs an aircraft carrierPostgres needs an aircraft carrier
Postgres needs an aircraft carrier
 
Mistakes were made
Mistakes were madeMistakes were made
Mistakes were made
 
Harder, better, faster, stronger: PostgreSQL 9.1
Harder, better, faster, stronger: PostgreSQL 9.1Harder, better, faster, stronger: PostgreSQL 9.1
Harder, better, faster, stronger: PostgreSQL 9.1
 
How to ask for money
How to ask for moneyHow to ask for money
How to ask for money
 
Letters from the open source trenches - Postgres community
Letters from the open source trenches - Postgres communityLetters from the open source trenches - Postgres community
Letters from the open source trenches - Postgres community
 
Own it: working with a changing open source community
Own it: working with a changing open source communityOwn it: working with a changing open source community
Own it: working with a changing open source community
 
Managing terabytes: When Postgres gets big
Managing terabytes: When Postgres gets bigManaging terabytes: When Postgres gets big
Managing terabytes: When Postgres gets big
 
Managing terabytes: When PostgreSQL gets big
Managing terabytes: When PostgreSQL gets bigManaging terabytes: When PostgreSQL gets big
Managing terabytes: When PostgreSQL gets big
 
Pdxpugday2010 pg90
Pdxpugday2010 pg90Pdxpugday2010 pg90
Pdxpugday2010 pg90
 
Illustrated buffer cache
Illustrated buffer cacheIllustrated buffer cache
Illustrated buffer cache
 
Bucardo
BucardoBucardo
Bucardo
 
How a bunch of normal people Used Technology To Repair a Rigged Election
How a bunch of normal people Used Technology To Repair a Rigged ElectionHow a bunch of normal people Used Technology To Repair a Rigged Election
How a bunch of normal people Used Technology To Repair a Rigged Election
 
Open Source Bridge Opening Day
Open Source Bridge Opening DayOpen Source Bridge Opening Day
Open Source Bridge Opening Day
 
What Assumptions Make: Filesystem I/O from a database perspective
What Assumptions Make: Filesystem I/O from a database perspectiveWhat Assumptions Make: Filesystem I/O from a database perspective
What Assumptions Make: Filesystem I/O from a database perspective
 

Dernier

Innovation Conference 5th March 2024.pdf
Innovation Conference 5th March 2024.pdfInnovation Conference 5th March 2024.pdf
Innovation Conference 5th March 2024.pdfrichard876048
 
Market Sizes Sample Report - 2024 Edition
Market Sizes Sample Report - 2024 EditionMarket Sizes Sample Report - 2024 Edition
Market Sizes Sample Report - 2024 EditionMintel Group
 
Investment in The Coconut Industry by Nancy Cheruiyot
Investment in The Coconut Industry by Nancy CheruiyotInvestment in The Coconut Industry by Nancy Cheruiyot
Investment in The Coconut Industry by Nancy Cheruiyotictsugar
 
Keppel Ltd. 1Q 2024 Business Update Presentation Slides
Keppel Ltd. 1Q 2024 Business Update  Presentation SlidesKeppel Ltd. 1Q 2024 Business Update  Presentation Slides
Keppel Ltd. 1Q 2024 Business Update Presentation SlidesKeppelCorporation
 
8447779800, Low rate Call girls in Uttam Nagar Delhi NCR
8447779800, Low rate Call girls in Uttam Nagar Delhi NCR8447779800, Low rate Call girls in Uttam Nagar Delhi NCR
8447779800, Low rate Call girls in Uttam Nagar Delhi NCRashishs7044
 
Case study on tata clothing brand zudio in detail
Case study on tata clothing brand zudio in detailCase study on tata clothing brand zudio in detail
Case study on tata clothing brand zudio in detailAriel592675
 
Annual General Meeting Presentation Slides
Annual General Meeting Presentation SlidesAnnual General Meeting Presentation Slides
Annual General Meeting Presentation SlidesKeppelCorporation
 
Future Of Sample Report 2024 | Redacted Version
Future Of Sample Report 2024 | Redacted VersionFuture Of Sample Report 2024 | Redacted Version
Future Of Sample Report 2024 | Redacted VersionMintel Group
 
The CMO Survey - Highlights and Insights Report - Spring 2024
The CMO Survey - Highlights and Insights Report - Spring 2024The CMO Survey - Highlights and Insights Report - Spring 2024
The CMO Survey - Highlights and Insights Report - Spring 2024christinemoorman
 
International Business Environments and Operations 16th Global Edition test b...
International Business Environments and Operations 16th Global Edition test b...International Business Environments and Operations 16th Global Edition test b...
International Business Environments and Operations 16th Global Edition test b...ssuserf63bd7
 
Digital Transformation in the PLM domain - distrib.pdf
Digital Transformation in the PLM domain - distrib.pdfDigital Transformation in the PLM domain - distrib.pdf
Digital Transformation in the PLM domain - distrib.pdfJos Voskuil
 
Pitch Deck Teardown: Geodesic.Life's $500k Pre-seed deck
Pitch Deck Teardown: Geodesic.Life's $500k Pre-seed deckPitch Deck Teardown: Geodesic.Life's $500k Pre-seed deck
Pitch Deck Teardown: Geodesic.Life's $500k Pre-seed deckHajeJanKamps
 
Call Girls In Sikandarpur Gurgaon ❤️8860477959_Russian 100% Genuine Escorts I...
Call Girls In Sikandarpur Gurgaon ❤️8860477959_Russian 100% Genuine Escorts I...Call Girls In Sikandarpur Gurgaon ❤️8860477959_Russian 100% Genuine Escorts I...
Call Girls In Sikandarpur Gurgaon ❤️8860477959_Russian 100% Genuine Escorts I...lizamodels9
 
MAHA Global and IPR: Do Actions Speak Louder Than Words?
MAHA Global and IPR: Do Actions Speak Louder Than Words?MAHA Global and IPR: Do Actions Speak Louder Than Words?
MAHA Global and IPR: Do Actions Speak Louder Than Words?Olivia Kresic
 
APRIL2024_UKRAINE_xml_0000000000000 .pdf
APRIL2024_UKRAINE_xml_0000000000000 .pdfAPRIL2024_UKRAINE_xml_0000000000000 .pdf
APRIL2024_UKRAINE_xml_0000000000000 .pdfRbc Rbcua
 
Buy gmail accounts.pdf Buy Old Gmail Accounts
Buy gmail accounts.pdf Buy Old Gmail AccountsBuy gmail accounts.pdf Buy Old Gmail Accounts
Buy gmail accounts.pdf Buy Old Gmail AccountsBuy Verified Accounts
 
Marketplace and Quality Assurance Presentation - Vincent Chirchir
Marketplace and Quality Assurance Presentation - Vincent ChirchirMarketplace and Quality Assurance Presentation - Vincent Chirchir
Marketplace and Quality Assurance Presentation - Vincent Chirchirictsugar
 
BEST Call Girls In Greater Noida ✨ 9773824855 ✨ Escorts Service In Delhi Ncr,
BEST Call Girls In Greater Noida ✨ 9773824855 ✨ Escorts Service In Delhi Ncr,BEST Call Girls In Greater Noida ✨ 9773824855 ✨ Escorts Service In Delhi Ncr,
BEST Call Girls In Greater Noida ✨ 9773824855 ✨ Escorts Service In Delhi Ncr,noida100girls
 

Dernier (20)

Innovation Conference 5th March 2024.pdf
Innovation Conference 5th March 2024.pdfInnovation Conference 5th March 2024.pdf
Innovation Conference 5th March 2024.pdf
 
Market Sizes Sample Report - 2024 Edition
Market Sizes Sample Report - 2024 EditionMarket Sizes Sample Report - 2024 Edition
Market Sizes Sample Report - 2024 Edition
 
Corporate Profile 47Billion Information Technology
Corporate Profile 47Billion Information TechnologyCorporate Profile 47Billion Information Technology
Corporate Profile 47Billion Information Technology
 
Investment in The Coconut Industry by Nancy Cheruiyot
Investment in The Coconut Industry by Nancy CheruiyotInvestment in The Coconut Industry by Nancy Cheruiyot
Investment in The Coconut Industry by Nancy Cheruiyot
 
Keppel Ltd. 1Q 2024 Business Update Presentation Slides
Keppel Ltd. 1Q 2024 Business Update  Presentation SlidesKeppel Ltd. 1Q 2024 Business Update  Presentation Slides
Keppel Ltd. 1Q 2024 Business Update Presentation Slides
 
8447779800, Low rate Call girls in Uttam Nagar Delhi NCR
8447779800, Low rate Call girls in Uttam Nagar Delhi NCR8447779800, Low rate Call girls in Uttam Nagar Delhi NCR
8447779800, Low rate Call girls in Uttam Nagar Delhi NCR
 
Case study on tata clothing brand zudio in detail
Case study on tata clothing brand zudio in detailCase study on tata clothing brand zudio in detail
Case study on tata clothing brand zudio in detail
 
Annual General Meeting Presentation Slides
Annual General Meeting Presentation SlidesAnnual General Meeting Presentation Slides
Annual General Meeting Presentation Slides
 
Future Of Sample Report 2024 | Redacted Version
Future Of Sample Report 2024 | Redacted VersionFuture Of Sample Report 2024 | Redacted Version
Future Of Sample Report 2024 | Redacted Version
 
The CMO Survey - Highlights and Insights Report - Spring 2024
The CMO Survey - Highlights and Insights Report - Spring 2024The CMO Survey - Highlights and Insights Report - Spring 2024
The CMO Survey - Highlights and Insights Report - Spring 2024
 
International Business Environments and Operations 16th Global Edition test b...
International Business Environments and Operations 16th Global Edition test b...International Business Environments and Operations 16th Global Edition test b...
International Business Environments and Operations 16th Global Edition test b...
 
Digital Transformation in the PLM domain - distrib.pdf
Digital Transformation in the PLM domain - distrib.pdfDigital Transformation in the PLM domain - distrib.pdf
Digital Transformation in the PLM domain - distrib.pdf
 
Pitch Deck Teardown: Geodesic.Life's $500k Pre-seed deck
Pitch Deck Teardown: Geodesic.Life's $500k Pre-seed deckPitch Deck Teardown: Geodesic.Life's $500k Pre-seed deck
Pitch Deck Teardown: Geodesic.Life's $500k Pre-seed deck
 
Call Girls In Sikandarpur Gurgaon ❤️8860477959_Russian 100% Genuine Escorts I...
Call Girls In Sikandarpur Gurgaon ❤️8860477959_Russian 100% Genuine Escorts I...Call Girls In Sikandarpur Gurgaon ❤️8860477959_Russian 100% Genuine Escorts I...
Call Girls In Sikandarpur Gurgaon ❤️8860477959_Russian 100% Genuine Escorts I...
 
MAHA Global and IPR: Do Actions Speak Louder Than Words?
MAHA Global and IPR: Do Actions Speak Louder Than Words?MAHA Global and IPR: Do Actions Speak Louder Than Words?
MAHA Global and IPR: Do Actions Speak Louder Than Words?
 
APRIL2024_UKRAINE_xml_0000000000000 .pdf
APRIL2024_UKRAINE_xml_0000000000000 .pdfAPRIL2024_UKRAINE_xml_0000000000000 .pdf
APRIL2024_UKRAINE_xml_0000000000000 .pdf
 
Buy gmail accounts.pdf Buy Old Gmail Accounts
Buy gmail accounts.pdf Buy Old Gmail AccountsBuy gmail accounts.pdf Buy Old Gmail Accounts
Buy gmail accounts.pdf Buy Old Gmail Accounts
 
Marketplace and Quality Assurance Presentation - Vincent Chirchir
Marketplace and Quality Assurance Presentation - Vincent ChirchirMarketplace and Quality Assurance Presentation - Vincent Chirchir
Marketplace and Quality Assurance Presentation - Vincent Chirchir
 
Japan IT Week 2024 Brochure by 47Billion (English)
Japan IT Week 2024 Brochure by 47Billion (English)Japan IT Week 2024 Brochure by 47Billion (English)
Japan IT Week 2024 Brochure by 47Billion (English)
 
BEST Call Girls In Greater Noida ✨ 9773824855 ✨ Escorts Service In Delhi Ncr,
BEST Call Girls In Greater Noida ✨ 9773824855 ✨ Escorts Service In Delhi Ncr,BEST Call Girls In Greater Noida ✨ 9773824855 ✨ Escorts Service In Delhi Ncr,
BEST Call Girls In Greater Noida ✨ 9773824855 ✨ Escorts Service In Delhi Ncr,
 

Algorithms are Recipes

  • 2. What is an algorithm?
  • 3. “A set of rules to be followed in problem solving operations.”
  • 5. Input Algorithm Output
  • 6. Input Algorithm Output “A set of rules to be followed in problem solving operations.”
  • 7. Input Algorithm Output • 2 slices bread “A set of rules to be • 1 tbsp peanut butter followed in problem • 2 tsp strawberry jam solving operations.”
  • 8. Input Algorithm Output • 2 slices bread “A set of rules to be • 1 tbsp peanut butter followed in problem • 2 tsp strawberry jam solving operations.”
  • 9. Input Algorithm Output • 2 slices bread • 1 tbsp peanut butter • 2 tsp strawberry jam
  • 10. Selena & Michelle’s PBJ algorithm How many steps do you think it will take?
  • 11. There’s more than one way to do it.
  • 12. """ (C) Gerold Penz) Python can be simple, too :-) """ for quant in range(99, 0, -1): if quant > 1: print quant, "bottles of beer on the wall,", quant, "bottles of beer." if quant > 2: suffix = str(quant - 1) + " bottles of beer on the wall." else: suffix = "1 bottle of beer on the wall." elif quant == 1: print "1 bottle of beer on the wall, 1 bottle of beer." suffix = "no more beer on the wall!" print "Take one down, pass it around,", suffix print "--"
  • 13. # (c) Barbara Shaurette def bottles(): for i in reversed(range(100)): if i > 0: b = "bottles" if i == 1: b = "bottle" print i, b, "of beer on the wall,", i, b, "of beer" print "Take one down, pass it around,", i-1, "bottles of beer on the wallnr" bottles()
  • 15. Example: Get from the airport to home.
  • 16. “The taxi algorithm” • Go to the taxi stand. • Get in a taxi. • Give the driver my address.
  • 17. “The call-me algorithm” • When your plane arrives, call my cell phone. • Meet me outside baggage claim.
  • 18. “The rent-a-car algorithm” • Take the shuttle to the rental car place. • Rent a car. • Follow the directions to get to my house.
  • 19. “The bus algorithm” • Outside baggage claim, catch bus number 70. • Transfer to bus 14 on Main Street. • Get off on Elm street. • Walk two blocks north to my house.
  • 20. All get you to where you need to go.

Notes de l'éditeur

  1. \n
  2. \n
  3. \n
  4. \n
  5. \n
  6. \n
  7. \n
  8. \n
  9. \n
  10. \n
  11. \n
  12. \n
  13. \n
  14. \n
  15. \n
  16. \n
  17. \n
  18. \n
  19. \n
  20. \n