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

Home > Logic
Rank The Magicians (Posted on 2007-05-08) Difficulty: 3 of 5
Six magicians A, B, C, D, E, F live in an island. Every Monday, the elders of the island rank the six magicians on their performance during the previous six days.

The rankings published on the previous Monday listed A 1st, B 2nd, C 3rd, D 4th, E 5th and F 6th.

This Mondayís ranking has each magician ranked in a different position than that of the previous Monday. We know that:

1. Bís change in ranking is greatest among the six magicians.

2. The product of Dís rankings for the two weeks is the same as the product of Fís rankings for the two weeks.

Determine the new rankings.

See The Solution Submitted by K Sengupta    
Rating: 2.6000 (5 votes)

Comments: ( Back to comment list | You must be logged in to post comments.)
Solution of course there's a computer solution also | Comment 3 of 8 |
(In reply to solution by Charlie)

DECLARE SUB permute (a$)
CLS
a$ = "abcdef": h$ = a$
DO
  good = 1
  FOR i = 1 TO 6
    IF MID$(a$, i, 1) = MID$(h$, i, 1) THEN good = 0: EXIT FOR
  NEXT
  IF good THEN
    ac = ABS(INSTR(a$, "a") - INSTR(h$, "a"))
    bc = ABS(INSTR(a$, "b") - INSTR(h$, "b"))
    cc = ABS(INSTR(a$, "c") - INSTR(h$, "c"))
    dc = ABS(INSTR(a$, "d") - INSTR(h$, "d"))
    ec = ABS(INSTR(a$, "e") - INSTR(h$, "e"))
    fc = ABS(INSTR(a$, "f") - INSTR(h$, "f"))
    IF bc > ac AND bc > cc AND bc > dc AND bc > ec AND bc > fc THEN
      d = INSTR(a$, "d")
      f = INSTR(a$, "f")
      IF 6 * f = 4 * d THEN
         PRINT a$
      END IF
    END IF
  END IF
 
  permute a$
LOOP UNTIL a$ = h$

also produces

caefbd


  Posted by Charlie on 2007-05-08 21:30:26
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 (9)
Unsolved Problems
Top Rated Problems
This month's top
Most Commented On

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