Alright, so at each step, they're trying to rule out as many wrong answers as they can until there's only one left, at which point they'll know the right answer. It works because they have different starting information and know the nature of each other's starting information, allowing them to combine information that they already know with the information communicated by the other person still not knowing the answer. Each time they say they don't know, that gives the other person some information—and they know they're giving each other this information. For example, say Sandy was told the sum is 84. When Peter says he doesn't know the answer, Sandy can immediately rule out (83,1) because that's the only pair of numbers with a product of 83. If Peter had been told that the product was 83, he'd have known the answer immediately. And Peter knows that Sandy can rule such pairs out. Every time Sandy says she doesn't know the answer, Peter can rule out from his remaining options the ones that he knows she has enough information to have known, had it been correct. And vice versa, repeating until one of them narrows it down to just one option.