You can prove this using induction.

Basis: the number of green-eyed person is one.
The only one person have green-eyed only see blue-eyed person then the
person discover herself is a green-eyed person.

Hipothesis Induction: If have n person with green-eyed then n person
commited suicide in n-th day.

Inductive step: There were n+1 green-eyed person. Each green-eyed person see
n green-eyed person. If nobody commited suicide after n days then the person
discover herself is a green-eyed person e commited suicide with n green-eyed
person


Wladimir Araujo Tavares
http://www.si.ufc.br/~wladimir <http://www.si.ufc.br/%7Ewladimir/>
"Fiz uma faculdade! Só não fiz a segunda porque acabaram os tijolos."




On Fri, Dec 17, 2010 at 5:29 AM, Aditya Agrawal <[email protected]> wrote:

> standard google version is here :
> http://the-technical-interview.blogspot.com/2007/02/goolge-question.html
>
>
> On Fri, Dec 17, 2010 at 12:49 PM, vamsee marpu <[email protected]>wrote:
>
>>
>>
>>
>>
>> Ans : Total 20 green-eyed people were there in the village.
>>
>>  --
>> You received this message because you are subscribed to the Google Groups
>> "Algorithm Geeks" group.
>> To post to this group, send email to [email protected].
>> To unsubscribe from this group, send email to
>> [email protected]<algogeeks%[email protected]>
>> .
>> For more options, visit this group at
>> http://groups.google.com/group/algogeeks?hl=en.
>>
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to
> [email protected]<algogeeks%[email protected]>
> .
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.

Reply via email to