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

Home > Logic
Distinct Seating Arrangements (Posted on 2024-06-23) Difficulty: 3 of 5
Mrs. Froopaloop has invited several wives of delegates to the United Nations for an informal luncheon. She plans to seat her 9 guests in a row such that each lady will be able to converse with the person directly to her left and right.
She has prepared the following list:
Mrs. Froopaloop speaks only English.
Mrs. Garot speaks English and French.
Mrs. Hakobyan speaks English and Russian.
Mrs. Jumaev speaks Russian only.
Mrs. Kelly speaks English only.
Mrs. Lafourcade speaks French only.
Mrs. Mendler speaks French and German.
Mrs. Nabe speaks English and German.
Mrs. Olson speaks English only.
How many distinct seating arrangements are possible?
Note that ABCD and DCBA are the same.

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.)
Solution Computer solution Comment 1 of 1
I found 126 solutions not counting mirror image reversals.
-----
d = {'F': 'e',
'G': 'ef',
'H': 'er',
'J': 'r',
'K': 'e',
'L': 'f',
'M': 'fg',
'N': 'eg',
'O': 'e'}

ladies = d.keys()

sols = []
from itertools import permutations
for perm in permutations(ladies):
    winner = True
    for i,p in enumerate(perm):
        if i == 0:
            continue
        a = d[p]
        b = d[perm[i-1]]
        if len(set(a+b)) == len(a) + len(b):
            winner = False
            break
    if winner:
        winstring = ''.join(perm)
        if winstring[0] < winstring[-1]:
            sols.append(winstring)
            print(winstring)
print(len(sols))

-----
FGLMNKOHJ
FGLMNOKHJ
FKGLMNOHJ
FKNMLGOHJ
FKOGLMNHJ
FKONMLGHJ
FNMLGKOHJ
FNMLGOKHJ
FOGLMNKHJ
FOKGLMNHJ
FOKNMLGHJ
FONMLGKHJ
GLMNFKOHJ
GLMNFOKHJ
GLMNKFOHJ
GLMNKOFHJ
GLMNOFKHJ
GLMNOKFHJ
JHFGKONML
JHFGLMNKO
JHFGLMNOK
JHFGOKNML
JHFKGLMNO
JHFKGONML
JHFKNMLGO
JHFKNOGLM
JHFKNOGML
JHFKOGLMN
JHFKOGNML
JHFKONGLM
JHFKONGML
JHFKONMGL
JHFNKOGLM
JHFNKOGML
JHFNMLGKO
JHFNMLGOK
JHFNOKGLM
JHFNOKGML
JHFOGKNML
JHFOGLMNK
JHFOKGLMN
JHFOKGNML
JHFOKNGLM
JHFOKNGML
JHFOKNMGL
JHFONKGLM
JHFONKGML
JHFONMLGK
JHGFKONML
JHGFOKNML
JHGKFONML
JHGKOFNML
JHGLMNFKO
JHGLMNFOK
JHGLMNKFO
JHGLMNOFK
JHGOFKNML
JHGOKFNML
JHKFGLMNO
JHKFGONML
JHKFNMLGO
JHKFNOGLM
JHKFNOGML
JHKFOGLMN
JHKFOGNML
JHKFONGLM
JHKFONGML
JHKFONMGL
JHKGFONML
JHKGLMNFO
JHKGOFNML
JHKNFOGLM
JHKNFOGML
JHKNMLGFO
JHKNOFGLM
JHKNOFGML
JHKOFGLMN
JHKOFGNML
JHKOFNGLM
JHKOFNGML
JHKOFNMGL
JHKOGFNML
JHKONFGLM
JHKONFGML
JHNFKOGLM
JHNFKOGML
JHNFOKGLM
JHNFOKGML
JHNKFOGLM
JHNKFOGML
JHNKOFGLM
JHNKOFGML
JHNMLGFKO
JHNMLGFOK
JHNMLGKFO
JHNMLGOFK
JHNOFKGLM
JHNOFKGML
JHNOKFGLM
JHNOKFGML
JHOFGKNML
JHOFGLMNK
JHOFKGLMN
JHOFKGNML
JHOFKNGLM
JHOFKNGML
JHOFKNMGL
JHOFNKGLM
JHOFNKGML
JHOFNMLGK
JHOGFKNML
JHOGKFNML
JHOGLMNFK
JHOKFGLMN
JHOKFGNML
JHOKFNGLM
JHOKFNGML
JHOKFNMGL
JHOKGFNML
JHOKNFGLM
JHOKNFGML
JHONFKGLM
JHONFKGML
JHONKFGLM
JHONKFGML
JHONMLGFK
126

  Posted by Larry on 2024-06-23 07:58:38
Please log in:
Login:
Password:
Remember me:
Sign up! | Forgot password


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

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