 All about flooble | fun stuff | Get a free chatterbox | Free JavaScript | Avatars  perplexus dot info  Simple Sequence (Posted on 2007-05-07) The sequence:

1, 3, 7, 13, 21, ...

What is the 600th member of the series?

What member, above the first, with fewer than 5 digits, is a perfect cube?

What member is a 5-digit palindrome that can also be read as a binary number?

What's the smaller of the two consecutive members that are 1000 apart?

 Submitted by Charlie Rating: 4.0000 (2 votes) Solution: (Hide) The sequence formula is n^2 - n + 1. The 600th is 359,401. 343 (the 19th member) is the perfect cube. 10101 (the 101st member) is the palindrome. The 500th member is the lower of the two that differ by 1000, and is 249,501. The program uses increasing first differences, rather than the formula: ```diff = 2: n = 1 DO ct = ct + 1 IF ct = 600 THEN PRINT "600th="; n tst = INT(n ^ (1 / 3) + .5): tcu = tst * tst * tst IF tcu = n THEN PRINT "cube "; n; ct ns\$ = LTRIM\$(STR\$(n)) IF LEN(ns\$) = 5 THEN IF LEFT\$(ns\$, 1) = RIGHT\$(ns\$, 1) AND MID\$(ns\$, 2, 1) = MID\$(ns\$, 4, 1) THEN good = 1 FOR i = 1 TO 3 IF INSTR("01", MID\$(ns\$, i, 1)) = 0 THEN good = 0 NEXT IF good THEN PRINT "bin pal="; n; ct END IF END IF END IF IF diff = 1000 THEN PRINT "lower="; n; ct n = n + diff diff = diff + 2 LOOP UNTIL ct > 600 AND diff > 1000 ``` which results in: ```cube 1 1 cube 343 19 bin pal= 10101 101 lower= 249501 500 600th= 359401 ``` From Enigma No. 1436 by Adrian Somerfield, New Scientist, 31 March 2007 Subject Author Date Problem Solution K Sengupta 2007-05-09 11:59:40 re: Please explain Charlie 2007-05-08 12:38:19 Please explain brianjn 2007-05-08 05:03:24 re: No Subject George 2007-05-07 21:42:05 No Subject Dej Mar 2007-05-07 20:51:19 Solution atheron 2007-05-07 10:40:57 Tease brianjn 2007-05-07 09:35:54 Please log in:

 Search: Search body:
Forums (0)