Author |
Topic: What a number! (Read 479 times) |
|
pcbouhid
Uberpuzzler
    


Gender: 
Posts: 647
|
 |
What a number!
« on: Dec 12th, 2005, 4:54pm » |
Quote Modify
|
Find a positive integer (base 10) which has the following four properties: (a) Each of the 10 digits (0 to 9) appears exactly once in the number. (b) For each pair of digits whose sum is 9, the number of other digits positioned strictly between the pair is equal to the smaller digit of the pair. Explaining better: between 2 an 7 (that sums to 9) there are 2 (the smallest number of the pair (2,7)) digits. (c) The sum of each pair of digits positioned at the same distance from opposite ends of the number is a prime number. (d) The difference between any 2 adjacent digits is greater than 1.
|
« Last Edit: Jan 4th, 2006, 8:09am by pcbouhid » |
IP Logged |
Don´t follow me, I´m lost too.
|
|
|
almaeihm
Newbie


Posts: 11
|
 |
Re: WHAT A NUMBER!
« Reply #1 on: Dec 12th, 2005, 11:32pm » |
Quote Modify
|
I'm not proud of the way I worked this problem out... it was not intellectual at all... and rather time-consuming… I used a word file... made a table with 10 slots... grouped the numbers into five groups of two so that each group can be dragged and dropped as one entity that meets condition# 2... then I started shuffling the groups around and flipping the pairs over… and finally I got this number which meets all conditions: 5831746290
|
|
IP Logged |
|
|
|
pcbouhid
Uberpuzzler
    


Gender: 
Posts: 647
|
 |
Re: WHAT A NUMBER!
« Reply #2 on: Dec 13th, 2005, 8:55am » |
Quote Modify
|
But you got it! Read "Maquiavel".
|
|
IP Logged |
Don´t follow me, I´m lost too.
|
|
|
Sjoerd Job Postmus
Full Member
  

Posts: 228
|
 |
Re: WHAT A NUMBER!
« Reply #3 on: Dec 14th, 2005, 11:00am » |
Quote Modify
|
Logic dictates: 0+9 = 9 => 0 digits between 0 and 9 1+8 = 9 => 1 digit between 1 and 8 2+7 = 9 => 2, etc 3+6 4+5 Let's start with the smallest range... *09* If, any number is around this, it has to be 2,7; 3,6 or 4,5... If none of these match, we know that 09 is on a side... Please note that the order of the sum-digits is irrelevent, I could write 2..7 or 7..2 without any change to the solution... Trial 1: 27 *2097* If we want to put anything around this at all, it has to be 45 *420975* This leaves us 2 pairs, 3,6; 1,8... we can't add those without problems. But, this would be the only way. From this follows that 09 isn't surrounded by 27. Trial 2: 36 3.096 OR 309.6 -- 3.096 -- Let's put the 18 around the 3 138096, we're left with 2 pairs: 27 and 45. We can't put the 45 [widest] around it, so it has to be next to it, leaving us a wider string. So, we do't put 18 around the 3 Let's try 45 34096.5 We're left with 18 and 27 If we put 18 there, we're left with 27 => slackspace. So. let's try 27 3409625.7 And add 18 3409625178 Yielding us a correct number. Adding to the table below -- 309.6 -- We know 18 causes a failure. Let's try 45 4.30956 27, then 18 1284730956 Yet another valid number. 3409625178 1284730956 Primeness check 3409625178: 11, 11, 1, 14, 8 FALSE 1284730956: 7, 7, 17, 4, 10 FALSE Hrm ... Well, at least I tried to deduct step 1 logically... !
|
|
IP Logged |
|
|
|
|