subject

The Power of If Worksheet
Output: Your goal
You will write a program that asks a user to answer a question, stores the response in a variable, and then prints a message based on the response.

Part 1: Plan and Write the Pseudocode
Using pseudocode, write an algorithm that someone else can follow.
1. Decide on a question to ask the user. Some ideas include:
1. What grade are you in?
2. What sport do you play?
3. Where did you go on vacation?
2. Use one variable to store the response.
3. Use one if-else statement to make a decision based on the user's input.
4. Display two messages; one for each condition (True and False).

Insert your pseudocode here: (you only need to do one)

Write it out:

Get input:

If statement:

Print if true:

Print if false:

Part 2: Code the Program
Use the following guidelines to code your program.
1. Use the Python IDLE to write your program.
2. Using comments, type a heading that includes your name, today’s date, and a short description.
3. Set up your def main(): statement. (Don’t forget the parentheses and colon.)
4. Write one if-else statement using user input.
5. Include a print message for both conditions (True and False).
6. Conclude the program with the main() statement.
7. Follow the Python style conventions regarding indentation in your program.
8. Run your program to ensure it is working properly. Fix any errors you may observe.
Part 3: Post Mortem Review (PMR)
Using complete sentences, respond to all the questions in the PMR chart.
Review Question Response
What was the purpose of your program?

How could your program be useful in the real world?

What is a problem you ran into, and how did you fix it?

Describe one thing you would do differently the next time you write a program.

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 02:00
Aisha has finished working on a word processing document that contains 15 pages. she has added some special elements in the first three pages, page 9 and 10, and page 15 from the document. she wants to print only these pages to see how they look. which option is the correct way to represent (in the print dialog box) the pages that aisha wants to print?
Answers: 1
question
Computers and Technology, 22.06.2019 05:00
Lisa has a section of her document that she would like to include in the index. which option should lisa choose? mark index mark entry insert endnote add text
Answers: 3
question
Computers and Technology, 22.06.2019 17:00
Which of the following is not contained on the slide show toolbar? a. next button b. slide button c. close button d. pen too
Answers: 2
question
Computers and Technology, 22.06.2019 21:00
Describir textbook icon_person mira los dibujos y describe lo que está pasando. usa los verbos de la lista.
Answers: 1
You know the right answer?
The Power of If Worksheet
Output: Your goal
You will write a program that asks a user...
Questions
question
Health, 20.02.2020 18:44
question
Mathematics, 20.02.2020 18:45
Questions on the website: 13722362