Tough logic puzzle

What is the basis for reason? And mathematics?

Moderators: AMod, iMod

Flannel Jesus
Posts: 4302
Joined: Mon Mar 28, 2022 7:09 pm

Tough logic puzzle

Post by Flannel Jesus »

This riddle was not invented by me, but I have changed all the details to avoid it being easy to look up the canonical answer.

There are 5 apartments in a row. In each apartment is a person with a unique hair color, nationality and preferred musical style. Every person is an artist in a unique medium. Each of the 5 front doors is colored a unique color. So, we're facing all 5 doors in front of us, and I give you the following information:

1. The guy with Black hair listens to Classical Music
2. The Photographer listens to Electronic Dance Music.
3. The guy next door to the Indian guy listens to Classical Music.
4. The middle door is painted Teal.
5. The sculptor's door is painted pink.
6. The red head is the right-hand neighbor (from our pov looking at the doors) of the Brunette.
7. The man who listens to Jazz lives in the apartment next to the Brazilian.
8. The oil painter lives next to the guy with grey hair.
9. The red head has a purple door.
10. The Digital Painter has blonde hair.
11. The Watercolor Painter is Canadian.
12. The oil painter lives in the first (leftmost) apartment.
13. The guy with the Orange door likes Reggae.
14. The Australian likes Hip Hop.

So, whose door is White? And what medium does the Kenyan use for his art?

This is deducible, but not easily. In fact all 5 properties of all 5 apartments are deducible.
User avatar
attofishpi
Posts: 13319
Joined: Tue Aug 16, 2011 8:10 am
Location: Orion Spur
Contact:

Re: Tough logic puzzle

Post by attofishpi »

Excellent!

Just out of interest, have you tested an AI on getting a solution?
User avatar
attofishpi
Posts: 13319
Joined: Tue Aug 16, 2011 8:10 am
Location: Orion Spur
Contact:

Re: Tough logic puzzle

Post by attofishpi »

Honestly, this is way harder than it looks (I haven't even bothered with the AI yet - no I shant!)

I've got an A4 piece of paper with arrows all over it. I then started a separate paper thinking I had enough info to start listing like an array - but noooo way off still.

I think the only way I could solve this would be structs and pointers - i shall continue on paper but I really really feel like a nice rolley of tobacco for some reason.
Flannel Jesus
Posts: 4302
Joined: Mon Mar 28, 2022 7:09 pm

Re: Tough logic puzzle

Post by Flannel Jesus »

attofishpi wrote: Tue Jul 16, 2024 8:52 am Excellent!

Just out of interest, have you tested an AI on getting a solution?
No but I can try

edit. ChatGPT 4o got it wrong.
User avatar
attofishpi
Posts: 13319
Joined: Tue Aug 16, 2011 8:10 am
Location: Orion Spur
Contact:

Re: Tough logic puzzle

Post by attofishpi »

DO IT!

I've got arrows on paper out of the wazoooo!
Flannel Jesus
Posts: 4302
Joined: Mon Mar 28, 2022 7:09 pm

Re: Tough logic puzzle

Post by Flannel Jesus »

attofishpi wrote: Tue Jul 16, 2024 9:32 am I think the only way I could solve this would be structs and pointers - i shall continue on paper but I really really feel like a nice rolley of tobacco for some reason.
May I make a recommendation?

Don't use pen and paper, use something digital, like Excel or google sheets.

There's PROBABLY going to be a point where you can't straight-forward deduce any more answers, so you're going to have to test some assumptions - for example, you'll want to test putting the watercolor painter here instead of there, and see if it produces a contradiction. Using spreadsheets, you can make copies of the spreadsheet and have each copy represent a different assumption.
User avatar
attofishpi
Posts: 13319
Joined: Tue Aug 16, 2011 8:10 am
Location: Orion Spur
Contact:

Re: Tough logic puzzle

Post by attofishpi »

Flannel Jesus wrote: Tue Jul 16, 2024 9:47 am
attofishpi wrote: Tue Jul 16, 2024 9:32 am I think the only way I could solve this would be structs and pointers - i shall continue on paper but I really really feel like a nice rolley of tobacco for some reason.
May I make a recommendation?

Don't use pen and paper, use something digital, like Excel or google sheets.

There's PROBABLY going to be a point where you can't straight-forward deduce any more answers, so you're going to have to test some assumptions - for example, you'll want to test putting the watercolor painter here instead of there, and see if it produces a contradiction. Using spreadsheets, you can make copies of the spreadsheet and have each copy represent a different assumption.
I haven't used spreadsheets in a long time - I know you can basically write code in excel for the logic..but nah if i'm going to go to that length to solve I'd do it using classes\structs n pointers. I'm tying another approach on paper - if that fails I'll probably cave.

I want to assume the Kenyan has black hair! - but I know that's not part of assumptions :lol:
Flannel Jesus
Posts: 4302
Joined: Mon Mar 28, 2022 7:09 pm

Re: Tough logic puzzle

Post by Flannel Jesus »

attofishpi wrote: Tue Jul 16, 2024 9:52 am I want to assume the Kenyan has black hair! - but I know that's not part of assumptions :lol:
That's right, and assuming that would definitely result in a contradiction with one of the premises if you try to solve the rest of the puzzle with that assumption.
I know you can basically write code in excel for the logic
That's not why I'm recommending it, I'm just recommending it so you can quickly copy your "board-state" to play with other possibilities.

I personally solved it with pencil and paper myself, and got the right answer, but then I watched a video of a guy solving it way faster by using the ability to copy-paste his board states. It was tedious re-creating the table by hand multiple times - I did it 4 or 5 times before I found the right assumptions.
User avatar
attofishpi
Posts: 13319
Joined: Tue Aug 16, 2011 8:10 am
Location: Orion Spur
Contact:

Re: Tough logic puzzle

Post by attofishpi »

Nah. I'm caving - well done for doing it on paper, impressed.

The amount of times I do a search through the 1-14 list of statements hoping there is more than 1 piece of info on any particular piece of data and there isn't...cbf. Honestly I don't know if I could do it these days, I know my cognition isn't what it was :|
Flannel Jesus
Posts: 4302
Joined: Mon Mar 28, 2022 7:09 pm

Re: Tough logic puzzle

Post by Flannel Jesus »

attofishpi wrote: Tue Jul 16, 2024 10:12 am Nah. I'm caving - well done for doing it on paper, impressed.

The amount of times I do a search through the 1-14 list of statements hoping there is more than 1 piece of info on any particular piece of data and there isn't...cbf. Honestly I don't know if I could do it these days, I know my cognition isn't what it was :|
Well there's about 6 different places on the grid you can fill out right away, I think. Have you done that already?
User avatar
attofishpi
Posts: 13319
Joined: Tue Aug 16, 2011 8:10 am
Location: Orion Spur
Contact:

Re: Tough logic puzzle

Post by attofishpi »

Honestly I haven't the time for it. The GPT thinks it has the answer but I won't post.
Flannel Jesus
Posts: 4302
Joined: Mon Mar 28, 2022 7:09 pm

Re: Tough logic puzzle

Post by Flannel Jesus »

attofishpi wrote: Tue Jul 16, 2024 10:16 am Honestly I haven't the time for it. The GPT thinks it has the answer but I won't post.
Go on, post what GPT thinks the answer is, let's see how retarded it is this time.
User avatar
attofishpi
Posts: 13319
Joined: Tue Aug 16, 2011 8:10 am
Location: Orion Spur
Contact:

Re: Tough logic puzzle

Post by attofishpi »

I think it's nailed EVERYTHING

Final Solution
The positions consistently satisfying all clues can be outlined as:

𝐴1 - (Grey, Canadian, Jazz, Oil Painter, White)
𝐴2 - (Brunette, Indian, Classical, Photographer, Pink)
𝐴3 - (Black, Brazilian, Classical, Digital Painter, Teal)
𝐴4 - (Red, Australian, Hip Hop, Sculptor, Purple)
𝐴5 - (Blonde, Kenyan, Reggae, Watercolor Painter, Orange)

Whose door is White?
The Canadian's door is White.

What medium does the Kenyan use for his art?
The Kenyan is a Watercolor Painter.
Flannel Jesus
Posts: 4302
Joined: Mon Mar 28, 2022 7:09 pm

Re: Tough logic puzzle

Post by Flannel Jesus »

attofishpi wrote: Tue Jul 16, 2024 10:22 am I think it's nailed EVERYTHING

Final Solution
The positions consistently satisfying all clues can be outlined as:

𝐴1 - (Grey, Canadian, Jazz, Oil Painter, White)
𝐴2 - (Brunette, Indian, Classical, Photographer, Pink)
𝐴3 - (Black, Brazilian, Classical, Digital Painter, Teal)
𝐴4 - (Red, Australian, Hip Hop, Sculptor, Purple)
𝐴5 - (Blonde, Kenyan, Reggae, Watercolor Painter, Orange)

Whose door is White?
The Canadian's door is White.

What medium does the Kenyan use for his art?
The Kenyan is a Watercolor Painter.
Not so. Let's see the entire board state and I'll show where it diverges from the clues

Edit. Whoops, you already posted the board state
Flannel Jesus
Posts: 4302
Joined: Mon Mar 28, 2022 7:09 pm

Re: Tough logic puzzle

Post by Flannel Jesus »

First contradiction found: you have 2 people listening to classical music.

Second contradiction, the photographer should listen to Electronic Dance Music.
Last edited by Flannel Jesus on Tue Jul 16, 2024 10:26 am, edited 1 time in total.
Post Reply