150 likes | 274 Views
Decision Structure in Java. Teacher: Mr. Ho. Agenda. Review: Software Development Life Cycle Decision Structure in Java Work Period: In-Class Exercise Bonus Question. What is Software Development Life Cycle?. Software Development Life Cycle. User Requirements. Planning & Design.
E N D
Decision Structure in Java Teacher: Mr. Ho
Agenda • Review: Software Development Life Cycle • Decision Structure in Java • Work Period: • In-Class Exercise • Bonus Question
Software Development Life Cycle User Requirements Planning & Design Implementation in Java Testing Maintenance
User Requirements • Write a computer program that: • Asks the user for a temperature value (in oC) • Outputs that it is cold if the temperature is less than 5oC
Planning & Design IPO Input Processing Output temperature temperature < 5 “cold”
Planning & Design Flowchart Start Prompt & ask for temperature (in oC) temperature < 5 YES Output “cold” No End
Implementation in Java • See BlueJ files
Testing • What is testing? • Why do we need to do testing?
Testing – Test Plan Test Cases: Does our program work correctly?
Maintenance • Write descriptive comments in the Java code
In-Class Activities • Go to the course web page at http://computerNHSS.wikispaces.com • Download today’s lesson and “2 – In-Class Activity on Decision Structure.docx” • Work on the In-Class Activity: • Follow the software development life cycle (i.e., planning & design, implementation, test plan, and maintenance) • If you are finished, let Mr. Ho know. • Bonus: • The temperature program in today’s lesson has a minor design flaw. Identify it and fix it. Then, you will get a bonus mark.