Tagged: by: ??? Toggle Comment Threads | Keyboard Shortcuts

  • Unknown's avatar

    Jim Randell 11:37 am on 2 January 2022 Permalink | Reply
    Tags: by: ???   

    An American Brain Teaser 

    From The Sunday Times, 5th June 1949 [link]

    The conundrum below below was said to have been posed by an American professor, with unflattering results, to an academic congress.

    A man calling on a friend in an American town saw a number of children playing in the garden. Without counting them he said to his host: “Surely they are not all yours?”. The other man replied: “No, there are four families, the largest being my own, the next largest my brother’s, the third largest my younger sister’s, and the smallest my elder sister’s. It is a pity that there are too few to make up a couple of base-ball teams”. (There are nine a side at base-ball).

    Then he added: “Oddly enough, the numbers of the four families of children, multiplied together, make the street number of this house”. The visitor, who knew the street number, thought for a moment and said: “Has the smallest family one or two children?”. His host having given the answer, he then stated with certainty how many there were in each family.

    How many were there?

    This one of the occasional Holiday Brain Teasers published in The Sunday Times prior to the start of numbered Teasers in 1961 that I have found. A prize of 10 guineas was offered.

    [teaser-1949-06-05] [teaser-unnumbered]

     
    • Jim Randell's avatar

      Jim Randell 11:38 am on 2 January 2022 Permalink | Reply

      This Python program runs in 51ms.

      Run: [ @replit ]

      from enigma import (irange, decompose, group, multiply, unpack, printf)
      
      # generate possible arrangements
      def generate():
        # consider the total number of children (< 18)
        for t in irange(10, 17):
          # break the total down into 4 families
          for ns in decompose(t, 4):
            yield ns
      
      # group the arrangements by product
      g = group(generate(), by=multiply)
      
      # consider products, and arrangements that make that product
      for (k, vs) in g.items():
        # there must be more than 1 arrangement
        if not (len(vs) > 1): continue
        # now group the arrangements by the smallest value ...
        g1 = group(vs, unpack(lambda a, b, c, d: a))
        # ... which must be 1 or 2
        if not (set(g1.keys()) == {1, 2}): continue
        # and find unique groups
        for (a, ns) in g1.items():
          if len(ns) == 1:
            printf("kids = {ns[0]}; k={k} vs={vs}")
      

      Solution: The numbers of children in the families were: 2, 3, 4, 5.


      The house number is 120, so the possible numbers of children are:

      (1, 3, 5, 8)
      (1, 4, 5, 6)
      (2, 3, 4, 5)

      The response for the number of children in the smallest family must be “2” (as “1” would not allow the numbers to be deduced), and this leads to a single arrangement.

      Like

    • GeoffR's avatar

      GeoffR 4:39 pm on 2 January 2022 Permalink | Reply

      % A Solution in MiniZinc
      % Look for three solutions - ref Jim's posting
      include "globals.mzn";
      
      int: total == 18; % max sum of ages < total
      var 24..360: num; % max UB = 3*4*5*6
      
      % Three solutions for 4 children
      var 1..10:a; var 1..10:b; var 1..10:c; var 1..10:d; 
      var 1..10:e; var 1..10:f; var 1..10:g; var 1..10:h; 
      var 1..10:i; var 1..10:j; var 1..10:k; var 1..10:m; 
      
      constraint all_different([a, b, c, d]);
      constraint all_different([e, f, g, h]);
      constraint all_different([i, j, k, m]);
      
      % max total ages for four children
      constraint a + b + c + d < total /\ e + f + g + h < total
       /\ i + j + k + m < total;
       
      % the smallest family has one or two children
      constraint a == 1 \/ a == 2;
      constraint e == 1 \/ e == 2;
      constraint i == 1 \/ i == 2;
      constraint a != e /\ a != i;
       
      % make (a,b,c,d) the smallest family - one or two children
      constraint (a + b + c + d) < (e + f + g + h) 
      /\ (e + f + g + h) < (i + j + k + m);
      
      % the street number of the house
      constraint num == a * b * c * d /\ num == e * f * g * h 
      /\ num == i * j * k * m;
      
      % put children's ages in order
      constraint increasing([a, b, c, d]) /\  increasing([e, f, g, h])
      /\ increasing ([i, j, k, m]);
      
      solve satisfy;
      
      output["House number = " ++ show(num) ++ "\n"
      ++ " Family children(1) = " ++ show([a, b, c, d]) ++ "\n"
      ++ " Family children(2) = " ++ show([e, f, g, h]) ++ "\n"
      ++ " Family children(3) = " ++ show([i, j, k, m]) ++ "\n" ];
      
      % House number = 120
      %  Family children(1) = [2, 3, 4, 5]  <<< Solution
      %  Family children(2) = [1, 4, 5, 6]
      %  Family children(3) = [1, 3, 5, 8]
      % ----------
      % ==========
      
      
      

      Like

  • Unknown's avatar

    Jim Randell 9:14 am on 26 December 2021 Permalink | Reply
    Tags: by: ???   

    A Brain-Teaser: [Square convoy] 

    From The Sunday Times, 2nd January 1949 [link]

    Four ships in convoy are at the corners of a square with sides one mile long. Ship B is due north of A; C is due east of B, and D is due south of C. The four ships are each sailing north at 10 miles per hour. A motor-boat, which travels at 26 miles per hour, starts at A, delivers a message to B, then to C, then to D, and finally returns to A. The distances between the ships are traversed by the shortest possible routes, and no allowance need be made for time taken in turning.

    How far does the convoy advance whilst the motor-boat is going round?

    This is earliest of the occasional Holiday Brain Teasers published in The Sunday Times prior to the start of numbered Teasers in 1961 that I have found. Prizes of 10 guineas and 5 guineas were awarded.

    This puzzle was originally published with no title.

    [teaser-1949-01-02] [teaser-unnumbered]

     
    • Jim Randell's avatar

      Jim Randell 9:16 am on 26 December 2021 Permalink | Reply

      (1) A to B:

      The position of the motorboat is given by: 26t

      And the position of B is given by: (1 + 10t)

      These coincide when:

      26t = 1 + 10t
      16t = 1
      t = 1/16

      (2) B to C:

      The motorboat travels along the hypotenuse of a right-angled triangle, a distance: 26t.

      And C travels along another side, a distance: 10t.

      The remaining side being of length 1.

      (26t)² = (10t)² + 1²
      676t² = 100t² + 1
      t² = 1/576
      t = 1/24

      (3) C to D:

      The motorboat’s position is: −26t.

      D’s position is: −1 + 10t.

      −26t = −1 + 10t
      t = 1/36

      (4) D to A:

      A mirror image of B to C.

      So the total time taken is:

      T = 1/16 + 1/24 + 1/36 + 1/24
      T = 25/144

      And the distance travelled by each boat in the fleet:

      D = 10T
      D = 125/72
      D = 1.736 miles
      D = 110000 inches = 1 mile, 1295 yards, 20 inches

      Solution: The distance travelled by the fleet was 1 mile, 1295 yards, 20 inches.

      Like

  • Unknown's avatar

    Jim Randell 9:31 am on 8 December 2020 Permalink | Reply
    Tags: by: ???   

    Brain-Teaser 44: The Omnibombulator 

    From The Sunday Times, 21st January 1962 [link]

    This unusual instrument is operated by selecting one of the four switch positions: A, B, C, D, and turning the power on. The effects are:

    A: The pratching valve glows and the queech obulates;
    B: The queech obulates and the urfer curls up, but the rumption does not get hot;
    C: The sneeveling rod turns clockwise, the pratching valve glows and the queech fails to obulate;
    D: The troglodyser gives off hydrogen but the urfer does not curl up.

    Whenever the pratching valve glows, the rumption gets hot. Unless the sneeveling rod turns clockwise, the queech cannot obulate, but if the sneeveling rod is turning clockwise the troglodyser will not emit hydrogen. If the urfer does not curl up, you may be sure that the rumption is not getting hot.

    In order to get milk chocolate from the machine, you must ensure:

    (a) that the sneeveling rod is turning clockwise AND;
    (b) that if the troglodyser is not emitting hydrogen, the queech is not obulating.

    1. Which switch position would you select to get milk chocolate?

    If, tiring of chocolate, you wish to receive the Third Programme, you must take care:

    (a) that the rumption does not get hot AND;
    (b) either that the urfer doesn’t curl and the queech doesn’t obulate or that the pratching valve glows and the troglodyser fails to emit hydrogen.

    2. Which switch position gives you the Third Programme?

    No setter was given for this puzzle.

    This puzzle crops up in several places on the web. (Although maybe it’s just because it’s easy to search for: “the queech obulates” doesn’t show up in many unrelated pages).

    And it is sometimes claimed it “appeared in a national newspaper in the 1930s” (although the BBC Third Programme was only broadcast from 1946 to 1967 (after which it became BBC Radio 3)), but the wording always seems to be the same as the wording in this puzzle, so it seems likely this is the original source (at least in this format).

    “Omnibombulator” is also the title of a 1995 book by Dick King-Smith.

    [teaser44]

     
    • Jim Randell's avatar

      Jim Randell 9:33 am on 8 December 2020 Permalink | Reply

      Consider the following conditions:

      P = “the pratching valve glows”
      Q = “the queech obulates”
      R = “the rumption gets hot”
      S = “the sneeveling rod turns clockwise”
      T = “the troglodyser gives off hydrogen”
      U = “the urfer curls up”

      Then the positions can be described as:

      A = P ∧ Q
      B = Q ∧ U ∧ ¬R
      C = S ∧ P ∧ ¬Q
      D = T ∧ ¬U

      And we are also given the following constraints:

      P → R
      Q → S
      S → ¬T
      ¬U → ¬R

      And the conditions that produce outcomes we are told about are:

      milk chocolate = S ∧ (¬T → ¬Q)
      third programme = ¬R ∧ ((¬U ∧ ¬Q) ∨ (P ∧ ¬T))

      The following Python program looks at all possible combinations of P, Q, R, S, T, U, and checks that the constraints are not violated, then looks for which positions are operated, and which outcomes occur.

      It runs in 49ms.

      Run: [ @replit ]

      from enigma import (subsets, implies, join, printf)
      
      # consider possible values of the statements
      for (P, Q, R, S, T, U) in subsets((True, False), size=6, select="M"):
      
        # check the constraint hold:
        # P -> R
        if not implies(P, R): continue
        # Q -> S
        if not implies(Q, S): continue
        # S -> not(T)
        if not implies(S, not T): continue
        # not(U) -> not(R) [same as: R -> U]
        if not implies(not U, not R): continue
      
        # which positions are operated?
        ps = list()
        if P and Q: ps.append('A')
        if Q and U and (not R): ps.append('B')
        if S and P and (not Q): ps.append('C')
        if T and (not U): ps.append('D')
      
        # possible outcomes
        ss = list()
        if S and implies(not T, not Q): ss.append('milk chocolate')
        if (not R) and (((not U) and (not Q)) or (P and (not T))): ss.append('third programme')
      
        # output solution
        if ps:
          if not ss: ss = [ "???" ]
          printf("{ps} -> ({ss}) {vs}", ps=join(ps, sep=","), ss=join(ss, sep=", "), vs=[P, Q, R, S, T, U])
      

      Solution: 1. Position C produces milk chocolate; 2. Position D gives you the Third Programme.

      We don’t know what A and B do, but we can describe their affects on the machine:

      A: the pratching valve glows; the queech obulates; the rumption gets hot; the sneeveling rod turns clockwise; the troglodyser does not give off hydrogen; the urfer curls up

      B: the pratching valve does not glow; the queech obulates; the rumption does not get hot; the sneeveling rod turns clockwise; the troglodyser does not give off hydrogen; the urfer curls up

      C: the pratching valve glows; the queech obulates; the rumption gets hot; the sneeveling rod turns clockwise; the troglodyser does not give off hydrogen; the urfer curls up

      D: the pratching valve does not glow; the queech does not obulate; the rumption does not get hot; the sneeveling rod turns anticlockwise; the troglodyser gives off hydrogen; the urfer does not curl up

      Like

    • John Crabtree's avatar

      John Crabtree 4:39 am on 14 December 2020 Permalink | Reply

      Let a positive action be represented by an uppercase letter, and a negative action by a lowercase letter.
      Expressed as Boolean logic where “.” means AND and “+” means OR, the conditions are:
      1. P.R + p = 1
      2. q.s + S.t = 1
      3. r.u + U = 1
      Combining 1 and 3 gives ( P.R + p).(r.u + U) = P.R.U + p.u.r + p.U = 1
      And so (P.R.U + p.r,u + p.U).(q.s + S,t) = 1

      The four switches give:
      A. P.Q = 1 and so P.R.U.Q.S.t = 1
      B. r.U.Q = 1 and so p.r.U.Q.S.t = 1
      C. P.q.S = 1, and so P.R.U.q.S.t = 1, (milk chocolate)
      D. u.T = 1 and so p.r.u.q.s.T = 1, (Third programme)

      Switch C selects milk chocolate. Switch D gets the Third programme.

      A similar technique can also be used in Brain-Teasers 506 and 520.

      Like

c
Compose new post
j
Next post/Next comment
k
Previous post/Previous comment
r
Reply
e
Edit
o
Show/Hide comments
t
Go to top
l
Go to login
h
Show/Hide help
shift + esc
Cancel
Design a site like this with WordPress.com
Get started