MagicJar

Example input:
3
4
1 2 3 4
4
7 3 5 2
3
1 5 10

Example output:
7
14
14

I'm not entirely sure if these are correct, though. I interpret the question as asking the minimum number of jars required given that the chefs take them in the worst possible order.

https://www.codechef.com/FEB19A/problems/MAGICJAR
Last edited on
Topic archived. No new replies allowed.