Answer:
1) I'd invent a device that would diagnose a person's disease or illness immediately, and would suggest the best course of treatment for them, and would also tell where to procure the treatment, as well as how to administer it.
2) I'd invent a device that shows the best way to divide resources like water, food etc. among the people and how to preserve them for as long as possible.
that's all i can think of.