Wednesday, May 25, 2022

Fractal Logic

Fancy a shot at an entertaining logical problem?

Fractal Logic
Photo by Sanjay Rawat/ Outlook

Maths and logic are obviously connected subjects. Some of the toughest, most intractable mathematical problems have been posed (and sometimes, solved) by logicians. But of course, there are also differences between the two disciplines. And sometimes, it is difficult to even categorise a problem as either "easy" or "difficult". That judgment is always subjective and linked to context.

Take the following logic puzzle as an example. Is it easy or difficult?

Albert (A), Bernard (B) and Cheryl (C) become friends. A and B ask C when her birthday is. C is a bit of a tease. She tells A the month, and she tells B the date. She tells both of them that it is one of the following ten dates and ask them to work it out: May 15, May 16, May 19, June 17, June 18, July 14, July 16, August 14, August 15, August 17.

A says: I don't know when C's birthday is, but I know that B also does not know.

B responds: If A's statement is true, then I now know when her birthday is.

A deduces: If B knows the birthday given the information above, then I also know the birthday.

Go through those statements one by one and you can also work it out.

B did not know the date instantly. There are some repeated numeric dates (14, 15, 16, 17) and two unique dates (June 18, May 19). If it was a unique date, B would know the birthday first-shot. So, it must be a date that is repeated.

A must know that it is in a month that does not contain a unique date to be sure that B does not know the date. May 19 is unique. So May is out. June 18 is unique. So June is out.

It can only be a date in July or August. In that set of dates, the 14th is in common and B would not be able to figure out the birthday, just from knowing it was on the 14th. Since B does work it out, the date must be July 16, or August 15, or August 17. A knows the month, of course. But A would have two alternatives in August, and would not be able to tell which date it was, if it was in August.

So it must be July 16 by elimination. This assumes of course, that Cheryl is not lying, or the possessor of two birthdays like a certain General-turned-politician.

Now, this seems like an entertaining and moderately difficult logical problem. It takes a while to parse all statements and eliminate the possibilities until we come to the only date that fits all criteria. It also involves an interesting switch of perspectives since one asks again and again, "What does A (or B) know at this stage?" No step is very tough but no step can be eliminated. There is no excess information, and every shred of info must be considered.

I can see how intelligent adults may get it wrong, or fail to make headway if they miss some detail. The problem has been posted in Facebook and on Reddit forums where many adults have got it wrong.

How do you think 14-15 year-olds would do at solving this? This is not an idle question. This problem was actually asked in a school maths exam in Singapore. I thought it would be difficult and actually somewhat "unfair" in a maths exam. It tests comprehension and logic as much as conventional maths knowledge or ability.

Surprise! When I showed it to my 12-year-old niece (who studies in a Delhi school), she solved it, going backwards from the answer by brute force. She took her time and considered and eliminated dates by repeatedly asking two connected questions as she looked at each date: "Can A tell it is this date, if it is this date?" & "Can B tell it is this date if it is this date? " I don't think she would have done it under a time limit but she did get there.

This made me wonder all over again, what is "easy" and what is "difficult". There is no arcane calculation, or special knowledge needed to solve this, although I would be instinctively averse to asking such a "hard" question of a child. But children do have plastic minds. There are certain problems they solve quicker than adults (Rubik's Cube for example, seems to be easier to solve if you are young). This may be one such problem. The brute force approach may also not be unusual for that age-group, given native comfort with computers.

Can working through this kind of logic problem help to train young minds? Probably and it may also help to keep the elderly from sliding into dementia. It certainly worked like a turbo-charger with my morning coffee.