After a long and successful day of preparation for the banquet, it's time to clean up. There is a list of tasks to be done before the kitchen closes at night. These activities are listed in 1 to n....


fdbcbcx


After a long and successful day of preparation for the banquet, it's time to clean up. There is<br>a list of tasks to be done before the kitchen closes at night. These activities are listed in 1 to<br>n.<br>Most of the cooks are already gone and only the Chef and his assistant are left to clean up.<br>Thankfully, some of the chefs took care of some of the tasks before they left so there is still<br>a set of tasks left. Chef and his assistant split up the remaining activities as follows. The<br>chef takes the unfinished job with a little index, the assistant takes the unfinished work with<br>at least a second index, the Chef takes on the unfinished work with at least a third index,<br>and so on. That is, if the unfinished tasks are listed in the index and then the Chef takes all<br>the rest and starts with the first task on the list and the assistant takes all the rest and starts<br>with the second task on the list.<br>The cooks signed up for what tasks they had completed before leaving. Unfortunately, these<br>activities are not listed for any specific order. Given the list of completed tasks, you should<br>decide what tasks the cook should cook and what tasks the certified person should perform<br>before closing the kitchen in the evening.<br>Design the program in Python programming language<br>Example<br>Input:<br>1<br>63<br>241<br>Output:<br>36<br>

Extracted text: After a long and successful day of preparation for the banquet, it's time to clean up. There is a list of tasks to be done before the kitchen closes at night. These activities are listed in 1 to n. Most of the cooks are already gone and only the Chef and his assistant are left to clean up. Thankfully, some of the chefs took care of some of the tasks before they left so there is still a set of tasks left. Chef and his assistant split up the remaining activities as follows. The chef takes the unfinished job with a little index, the assistant takes the unfinished work with at least a second index, the Chef takes on the unfinished work with at least a third index, and so on. That is, if the unfinished tasks are listed in the index and then the Chef takes all the rest and starts with the first task on the list and the assistant takes all the rest and starts with the second task on the list. The cooks signed up for what tasks they had completed before leaving. Unfortunately, these activities are not listed for any specific order. Given the list of completed tasks, you should decide what tasks the cook should cook and what tasks the certified person should perform before closing the kitchen in the evening. Design the program in Python programming language Example Input: 1 63 241 Output: 36

Jun 01, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here