All about flooble | fun stuff | Get a free chatterbox | Free JavaScript | Avatars    
perplexus dot info

Home > Logic
Butcher and Baker Puzzle (Posted on 2022-12-14) Difficulty: 3 of 5
Exactly one of Mr. Jankowski, Mrs. Jankowski, their son Nate, and their daughter Mabel is a butcher.

Five facts relating to their occupation are furnished hereunder as follows:

  1. If the butcher and the baker belong to the same sex, then the baker is older than the butcher.
  2. There is exactly one butcher and one baker.
  3. If neither the butcher nor the baker is the parent of the other, then the butcher is older than the baker.
  4. If the butcher is a man, then he and the baker are the same age.
  5. If the butcher and the baker belong to the opposite sex, then the man is older than the woman.
Whose occupation can be determined with certainty? Provide valid reasoning for your conclusion.

See The Solution Submitted by K Sengupta    
Rating: 5.0000 (1 votes)

Comments: ( Back to comment list | You must be logged in to post comments.)
different coding | Comment 5 of 30 |
I did first solve the problem with a computer code, which I then :-) ignored and concluded the wrong answer with 
mistaken logic. I should have checked with the code....

some output...

 father   age=           4 baker  
 mother   age=           4        
 son      age=           4        
 daughter age=           3 butcher

 father   age=           1        
 mother   age=           2 baker  
 son      age=           1        
 daughter age=           1 butcher


        program fam
        implicit none
        integer f(4,2),role,irole,agef,agem,ageb,ages,bak,fambak
        character rol(4)*8, job(3)*7
        data rol/'father','mother','son','daughter'/,job/'butcher','baker',' '/

c         (i,*): i=1,2,3,4     role:   father, mother, son, daughter
c         (*,1):  =1,2,3,4     age:    any of 4 relative possibilities
c         (*,2):  =1,2,3       job:    butcher, baker, none
        f(4,2)=1 ! daughter is butcher
           do fambak=1,3  ! who is the baker? 
           f(fambak,2)=2   ! ** 2 ** there is now a baker, and it is not Mabel
                do agef=1,4
                 do agem=1,4
                  do ageb=1,4
                   do 1 ages=1,4
                   if(bak.eq.2.and.f(2,1).le.f(4,1))go to 1 ! ** 1 **
                   if(bak.eq.3.and.f(4,1).le.f(3,1))go to 1 ! ** 3 **
c ** 4 ** is false already
        if((bak.eq.1.or.bak.eq.3).and.f(bak,1).le.f(4,1)) go to 1 ! ** 5 **
                        do irole=1,4
                        print*,rol(irole),' age=',f(irole,1),job(f(irole,2))
1                  enddo

  Posted by Steven Lord on 2022-12-14 10:24:46
Please log in:
Remember me:
Sign up! | Forgot password

Search body:
Forums (0)
Newest Problems
Random Problem
FAQ | About This Site
Site Statistics
New Comments (9)
Unsolved Problems
Top Rated Problems
This month's top
Most Commented On

Copyright © 2002 - 2024 by Animus Pactum Consulting. All rights reserved. Privacy Information