« Looking thru Windows - It's almost summer! | Main | Easy Lover, She will get a hold on you ! »

What knocks your socks off - You may ask.

My answer to this is pretty much everything does it to me! Well, not exactly. Specially when I have sound sleep, I don't think anything knocks my socks off during that time :).

 

If I asked my younger kid (who about to start High School) the following - You have 9 socks in a drawer. There are 3 black socks and 6 socks. What is the minimim number of socks you will pick up ( without looking at the colors) so that you get a pair of socks of same color. Not that he does not know the answer to it but being funny as they are (mainly because we were successful to inject the humor in their brain from early days of their lovely life ), he might respond like the following -

1) I will drop everything on the floor then pick two of the same color, what is the big deal Baba(i.e. Dad) ? And I will try to explain it is a little puzzle so without looking at them you have to come up with two socks of same color.

2) He might respond - Baba, who told you that I've have to have the same color to put on. Also how do you know that I need to wear exactly two of them. I might just be fine using one and the other could be without a sock or I even might say forget it, I will just put my shoes on without any socks.

And I would not ask this question to the elder boy, he might seriously laugh at me and could say - Baba, you are sick, so sick, sooooo sick and walk out without answering me. And I would be totally confused, he really really meant to say I'm sick or it is just brilliant question and he loves it. You know the kids talk, right? When they see something that excites them really - they say, it soooo sick Baba. I just love it, I'm a big fan of these puching of words, and I think that makes the langugage, conversation, and communications so sick :)

But this question is dedicated to my wife - It's mother's day, and she is solving math problems being a teacher by profession....

The answer is easy, if we draw 3, we will have a pair of same color.

Okay now you own 1 red sock, 2 indigo socks, 3 blue socks, 4 green socks, 5 yellow socks, 6 orange socks, and 7 violet socks.

It is not that difficult, but formalizing might require a bit of thinking! Well, this not the real problem I'm about to embark on, so it would be instructive to play around the little examples like the first one and change the parameters and see if you can find the patterns. So first find the parameter(s), then change them. Once you find the patterns there is an underlying mathematical concept lurking behind it that we often conciously or unconciously use when programming :).  

So you warmed up, right? Now the original problem that is the subject to this blog -

 

A drawer contains red socks and black socks. When two socks are drawn randomly, probaility that both socks are red is 1/2. (a) How small can the number of socks  in the drawer be? (b) How small the number of socks in the drawer be, if the number of black socks is even?

Well this is not going to be easy, and I will try to sketch the area of logic and math required to solve this. Once I knew all the areas involved in solving this type of problem, but solving few of them like this is the real challenge I think. So I will step thru some procedures that solves this, and it is definitely not my steps...  So next time I will illustrate the steps for solving this kind of problems, and it would be even more interesting to program the observations to see how it works!

 

Now back to the last blog's solution. Remember that we were given 1000 coins that are laid out as a line. The coins are in different dominations. Alice's objective to win by grabing more money than her opponent, well of course following the rule. If not then at least get even...

The problem has some structures (1) If Alice determines that picking just the odd numbered will give her the winning chance, then she could apply a process that force the opponent to pick even numbered coin. (2) Similarly it is true the Alice could win just my sticking to odd numbered (positioned) coins.

So Alice first run thru the coins and adds the values of odd positioned coins in one one sum, and do the same for even positioned. Now compare the two sums. If the odd positioned sum is greater than even positioned sum, pick the first odd positioned coined that happens to be at the start. 

Rest does not need any explanation!

 

Finally I would take the liberty to recommend two books -

1) Choice and chance by W.A. Whitworth

2) Algorithms and Programming Problems by Alexander Shen.

Posted on Sunday, May 8, 2011 at 11:20AM by Registered CommenterProkash Sinha | CommentsPost a Comment | References2 References

References (2)

References allow you to track sources for this article, as well as articles that were written in response to this article.
  • Response
    The good brand has given us much quality of the socks. The best quality can be available from the different qualities from the different factories. The main source of the main causes will be refining in the same ways.
  • Response
    Response: mens socks

Reader Comments

There are no comments for this journal entry. To create a new comment, use the form below.

PostPost a New Comment

Enter your information below to add a new comment.

My response is on my own website »
Author Email (optional):
Author URL (optional):
Post:
 
All HTML will be escaped. Hyperlinks will be created for URLs automatically.