In python    You have decided to track your productivity hours. The tracker will have a count for each day of the week. You will log hours each day even if the answer was 0 hours. Ask a person using the program you are writing how many hours they were productive each day.  The question is "How many hours were you productive on day {weekday}: " The day will be referred to as Day 1 or Day 2 or Day 3 etc. Use a while loop to control the process of asking a user for the information.  After the person provides their productivity hours for each day, print the total_productive_hours  total as it changes every day. Please note that you are not supposed to write a function or procedure. Write just the code needed. If you look at example 1 this is how the program would work:   The program starts and asks the person how productive they were on day 1. The user types the answer (input, see left column) 1. Then the program prints the tally total as being 1. The program starts and asks the person how productive they were on day 2. The user types the answer (input, see left column) 3. Then the program prints the tally total as being 4. The program starts and asks the person how productive they were on day 3. The user types the answer (input, see left column) 4. Then the program prints the tally total as being 8. The program starts and asks the person how productive they were on day 4. The user types the answer (input, see left column) 5. Then the program prints the tally total as being 13. The program starts and asks the person how productive they were on day 5. The user types the answer (input, see left column) 6. Then the program prints the tally total as being 19. The program starts and asks the person how productive they were on day 6. The user types the answer (input, see left column) 2. Then the program prints the tally total as being 21. The program starts and asks the person how productive they were on day 7. The user types the answer (input, see left column) 2. Then the program prints the tally total as being 23. The program stops asking the user for information because it has already asked for information for 7 days.     For example: Input Result 1 3 4 5 6 2 2 How many hours were you productive on day 1: 1 How many hours were you productive on day 2: 4 How many hours were you productive on day 3: 8 How many hours were you productive on day 4: 13 How many hours were you productive on day 5: 19 How many hours were you productive on day 6: 21 How many hours were you productive on day 7: 23 3 5 6 22 5 6 9 How many hours were you productive on day 1: 3 How many hours were you productive on day 2: 8 How many hours were you productive on day 3: 14 How many hours were you productive on day 4: 36 How many hours were you productive on day 5: 41 How many hours were you productive on day 6: 47 How many hours were you productive on day 7: 56 3 4 6 6 5 11 23 How many hours were you productive on day 1: 3 How many hours were you productive on day 2: 7 How many hours were you productive on day 3: 13 How many hours were you productive on day 4: 19 How many hours were you productive on day 5: 24 How many hours were you productive on day 6: 35 How many hours were you productive on day 7: 58

Computer Networking: A Top-Down Approach (7th Edition)
7th Edition
ISBN:9780133594140
Author:James Kurose, Keith Ross
Publisher:James Kurose, Keith Ross
Chapter1: Computer Networks And The Internet
Section: Chapter Questions
Problem R1RQ: What is the difference between a host and an end system? List several different types of end...
icon
Related questions
Question

In python 

 

You have decided to track your productivity hours. The tracker will have a count for each day of the week. You will log hours each day even if the answer was 0 hours.

  • Ask a person using the program you are writing how many hours they were productive each day.  The question is "How many hours were you productive on day {weekday}: " The day will be referred to as Day 1 or Day 2 or Day 3 etc.
  • Use a while loop to control the process of asking a user for the information. 
  • After the person provides their productivity hours for each day, print the total_productive_hours  total as it changes every day.
  • Please note that you are not supposed to write a function or procedure. Write just the code needed.

If you look at example 1 this is how the program would work:

 

  1. The program starts and asks the person how productive they were on day 1. The user types the answer (input, see left column) 1. Then the program prints the tally total as being 1.
  2. The program starts and asks the person how productive they were on day 2. The user types the answer (input, see left column) 3. Then the program prints the tally total as being 4.
  3. The program starts and asks the person how productive they were on day 3. The user types the answer (input, see left column) 4. Then the program prints the tally total as being 8.
  4. The program starts and asks the person how productive they were on day 4. The user types the answer (input, see left column) 5. Then the program prints the tally total as being 13.
  5. The program starts and asks the person how productive they were on day 5. The user types the answer (input, see left column) 6. Then the program prints the tally total as being 19.
  6. The program starts and asks the person how productive they were on day 6. The user types the answer (input, see left column) 2. Then the program prints the tally total as being 21.
  7. The program starts and asks the person how productive they were on day 7. The user types the answer (input, see left column) 2. Then the program prints the tally total as being 23.
  8. The program stops asking the user for information because it has already asked for information for 7 days.

 

 

For example:

Input Result
1 3 4 5 6 2 2 How many hours were you productive on day 1: 1 How many hours were you productive on day 2: 4 How many hours were you productive on day 3: 8 How many hours were you productive on day 4: 13 How many hours were you productive on day 5: 19 How many hours were you productive on day 6: 21 How many hours were you productive on day 7: 23
3 5 6 22 5 6 9 How many hours were you productive on day 1: 3 How many hours were you productive on day 2: 8 How many hours were you productive on day 3: 14 How many hours were you productive on day 4: 36 How many hours were you productive on day 5: 41 How many hours were you productive on day 6: 47 How many hours were you productive on day 7: 56
3 4 6 6 5 11 23 How many hours were you productive on day 1: 3 How many hours were you productive on day 2: 7 How many hours were you productive on day 3: 13 How many hours were you productive on day 4: 19 How many hours were you productive on day 5: 24 How many hours were you productive on day 6: 35 How many hours were you productive on day 7: 58
Expert Solution
steps

Step by step

Solved in 3 steps with 1 images

Blurred answer
Recommended textbooks for you
Computer Networking: A Top-Down Approach (7th Edi…
Computer Networking: A Top-Down Approach (7th Edi…
Computer Engineering
ISBN:
9780133594140
Author:
James Kurose, Keith Ross
Publisher:
PEARSON
Computer Organization and Design MIPS Edition, Fi…
Computer Organization and Design MIPS Edition, Fi…
Computer Engineering
ISBN:
9780124077263
Author:
David A. Patterson, John L. Hennessy
Publisher:
Elsevier Science
Network+ Guide to Networks (MindTap Course List)
Network+ Guide to Networks (MindTap Course List)
Computer Engineering
ISBN:
9781337569330
Author:
Jill West, Tamara Dean, Jean Andrews
Publisher:
Cengage Learning
Concepts of Database Management
Concepts of Database Management
Computer Engineering
ISBN:
9781337093422
Author:
Joy L. Starks, Philip J. Pratt, Mary Z. Last
Publisher:
Cengage Learning
Prelude to Programming
Prelude to Programming
Computer Engineering
ISBN:
9780133750423
Author:
VENIT, Stewart
Publisher:
Pearson Education
Sc Business Data Communications and Networking, T…
Sc Business Data Communications and Networking, T…
Computer Engineering
ISBN:
9781119368830
Author:
FITZGERALD
Publisher:
WILEY