Maybe?
ppppppppppp
double click and it select all in a code block
than right click and copy
than paste into thinAir
Please be sure to have latest thinBasic version: http://www.thinbasic.com/community/s...c-Beta-1.8.7.0
www.thinbasic.com | www.thinbasic.com/community/ | help.thinbasic.com
Windows 10 Pro for Workstations 64bit - 32 GB - Intel(R) Xeon(R) W-10855M CPU @ 2.80GHz - NVIDIA Quadro RTX 3000
Maybe?
ppppppppppp
Last edited by danbaron; 27-05-2011 at 01:13.
"You can't cheat an honest man. Never give a sucker an even break, or smarten up a chump." - W.C.Fields
I tried it for 4D.
For n = 200, I got 68,685,050 trials, and 124,768 successes.
I showed the list for n = 30.
Then, I extracted the 4D cubes.
----------------------------------------------------------------
Is there a better word than, "I", when I am the one using it?
- yes
- no
- undecided
- no comment
' code ----------------------------------------------------------------------------------------------------------------- #lang racket (define list-list (list)) (define selection-list (list)) (define (list-4D-integer-right-triangles n) (define a 0) (define b 0) (define c 0) (define d 0) (define e 0) (define count1 0) (define count2 0) (define count3 0) (define count4 0) (define tot-count 0) (set! list-list null) (define (loop1) (set! count1 (add1 count1)) (cond ((> count1 n) (values tot-count (length list-list) list-list)) (else (set! count2 (- count1 1)) (loop2) (loop1)))) (define (loop2) (set! count2 (add1 count2)) (cond ((> count2 n)) (else (set! count3 (- count2 1)) (loop3) (loop2)))) (define (loop3) (set! count3 (add1 count3)) (cond ((> count3 n)) (else (set! count4 (- count3 1)) (loop4) (loop3)))) (define (loop4) (set! count4 (add1 count4)) (cond ((> count4 n)) (else (set! tot-count (add1 tot-count)) (set! a count1) (set! b count2) (set! c count3) (set! d count4) (set! e (sqrt (+ (expt a 2) (expt b 2) (expt c 2) (expt d 2)))) (when (= e (floor e)) (set! list-list (append list-list (list (list a b c d e))))) (loop4)))) (loop1)) (define (extract-cubes l) (set! selection-list null) (define (loop l1) (cond ((empty? l1) selection-list) (else (define test (car l1)) (when (= (first test) (second test) (third test) (fourth test)) (set! selection-list (append selection-list (list test)))) (loop (cdr l1))))) (loop l)) ' REPL interactions ---------------------------------------------------------------------------------------------------- Welcome to DrRacket, version 5.1 [3m]. Language: racket. > (list-4D-integer-right-triangles 100) 4421275 16275 > (list-4D-integer-right-triangles 200) 68685050 124768 > (list-4D-integer-right-triangles 30) 40920 530 '((1 1 1 1 2) (1 1 3 5 6) (1 1 5 13 14) (1 1 7 7 10) (1 1 7 25 26) (1 1 11 19 22) (1 1 13 27 30) (1 1 23 25 34) (1 2 2 4 5) (1 2 4 10 11) (1 2 6 20 21) (1 2 8 10 13) (1 2 10 16 19) (1 2 18 20 27) (1 3 3 9 10) (1 3 5 17 18) (1 3 7 29 30) (1 3 15 21 26) (1 3 19 23 30) (1 4 4 4 7) (1 4 4 16 17) (1 4 6 26 27) (1 4 8 12 15) (1 4 10 18 21) (1 4 16 16 23) (1 4 26 26 37) (1 5 5 7 10) (1 5 5 25 26) (1 5 7 11 14) (1 5 11 23 26) (1 5 13 17 22) (1 5 17 19 26) (1 5 17 29 34) (1 7 7 15 18) (1 7 11 27 30) (1 7 15 25 30) (1 8 8 20 23) (1 8 10 14 19) (1 8 10 26 29) (1 8 22 26 35) (1 9 11 11 18) (1 9 17 23 30) (1 9 29 29 42) (1 10 12 14 21) (1 10 12 22 27) (1 10 16 22 29) (1 10 22 28 37) (1 12 18 30 37) (1 13 17 21 30) (1 13 19 25 34) (1 15 15 15 26) (1 16 16 24 33) (1 16 22 22 35) (1 17 23 25 38) (1 18 18 24 35) (1 20 22 22 37) (2 2 2 2 4) (2 2 3 8 9) (2 2 4 5 7) (2 2 5 16 17) (2 2 6 10 12) (2 2 7 8 11) (2 2 7 28 29) (2 2 8 17 19) (2 2 10 26 28) (2 2 11 20 23) (2 2 12 17 21) (2 2 13 28 31) (2 2 14 14 20) (2 2 16 19 25) (2 2 27 28 39) (2 3 4 14 15) (2 3 6 24 25) (2 3 20 26 33) (2 4 4 8 10) (2 4 5 6 9) (2 4 5 22 23) (2 4 6 13 15) (2 4 7 10 13) (2 4 8 20 22) (2 4 10 13 17) (2 4 10 29 31) (2 4 11 22 25) (2 4 13 30 33) (2 4 14 15 21) (2 4 14 25 29) (2 4 15 22 27) (2 4 16 20 26) (2 4 23 26 35) (2 5 8 14 17) (2 5 10 20 23) (2 5 14 20 25) (2 5 16 26 31) (2 5 22 24 33) (2 6 6 18 20) (2 6 8 11 15) (2 6 8 25 27) (2 6 12 21 25) (2 6 15 24 29) (2 6 17 20 27) (2 7 8 18 21) (2 7 10 24 27) (2 8 8 8 14) (2 8 10 11 17) (2 8 10 19 23) (2 8 11 30 33) (2 8 14 19 25) (2 8 16 24 30) (2 8 17 22 29) (2 8 25 26 37) (2 9 10 16 21) (2 10 10 14 20) (2 10 11 20 25) (2 10 12 29 33) (2 10 13 16 23) (2 10 14 22 28) (2 10 15 20 27) (2 10 16 27 33) (2 10 24 29 39) (2 13 14 16 25) (2 14 14 30 36) (2 14 19 20 31) (2 14 20 25 35) (2 16 17 26 35) (2 16 19 30 39) (2 16 20 28 38) (2 16 22 25 37) (2 17 20 26 37) (2 18 19 20 33) (2 18 22 22 36) (2 20 21 26 39) (2 20 24 28 42) (2 24 27 30 47) (2 30 30 30 52) (3 3 3 3 6) (3 3 3 13 14) (3 3 5 21 22) (3 3 9 15 18) (3 3 21 21 30) (3 4 4 20 21) (3 4 6 30 31) (3 4 10 10 15) (3 5 5 29 30) (3 5 9 9 14) (3 5 11 13 18) (3 5 15 15 22) (3 6 6 12 15) (3 6 10 12 17) (3 6 12 30 33) (3 6 16 18 25) (3 6 24 30 39) (3 8 12 12 19) (3 8 16 20 27) (3 8 24 24 35) (3 9 9 27 30) (3 9 13 15 22) (3 9 15 19 26) (3 9 15 29 34) (3 9 21 25 34) (3 9 25 27 38) (3 10 14 28 33) (3 12 12 12 21) (3 12 18 22 31) (3 13 19 19 30) (3 14 20 22 33) (3 14 24 30 41) (3 15 15 21 30) (3 17 25 29 42) (3 20 30 30 47) (4 4 4 4 8) (4 4 4 11 13) (4 4 5 8 11) (4 4 5 28 29) (4 4 6 16 18) (4 4 7 12 15) (4 4 8 10 14) (4 4 8 23 25) (4 4 11 24 27) (4 4 12 20 24) (4 4 14 16 22) (4 4 16 21 27) (4 4 20 23 31) (4 4 28 28 40) (4 5 8 8 13) (4 5 8 16 19) (4 5 10 22 25) (4 5 12 16 21) (4 5 20 20 29) (4 5 20 28 35) (4 6 6 9 13) (4 6 6 21 23) (4 6 8 28 30) (4 6 10 17 21) (4 6 14 29 33) (4 6 19 26 33) (4 6 27 30 41) (4 7 8 20 23) (4 7 10 14 19) (4 7 10 26 29) (4 7 22 26 35) (4 8 8 9 15) (4 8 8 16 20) (4 8 10 12 18) (4 8 12 26 30) (4 8 14 20 26) (4 8 15 28 33) (4 8 16 17 25) (4 8 16 25 31) (4 8 19 20 29) (4 8 19 28 35) (4 8 20 26 34) (4 8 28 30 42) (4 10 10 15 21) (4 10 10 25 29) (4 10 13 26 31) (4 10 14 23 29) (4 10 16 28 34) (4 10 17 18 27) (4 10 19 22 31) (4 10 22 25 35) (4 10 26 27 39) (4 11 14 14 23) (4 11 22 30 39) (4 12 12 15 23) (4 12 13 20 27) (4 12 15 24 31) (4 12 16 22 30) (4 12 20 23 33) (4 13 16 20 29) (4 13 16 28 35) (4 13 20 28 37) (4 14 22 23 35) (4 16 16 16 28) (4 16 16 29 37) (4 16 17 20 31) (4 16 20 22 34) (4 16 25 28 41) (4 18 21 30 41) (4 20 20 28 40) (4 20 23 24 39) (4 21 28 28 45) (4 22 25 30 45) (4 25 28 28 47) (4 26 26 29 47) (5 5 5 5 10) (5 5 5 11 14) (5 5 7 15 18) (5 5 11 27 30) (5 5 15 25 30) (5 6 8 10 15) (5 6 12 18 23) (5 6 18 24 31) (5 6 26 28 39) (5 7 7 19 22) (5 7 9 13 18) (5 7 11 17 22) (5 7 23 29 38) (5 8 8 24 27) (5 8 10 10 17) (5 8 10 30 33) (5 8 14 26 31) (5 8 18 26 33) (5 9 13 25 30) (5 10 10 20 25) (5 11 13 13 22) (5 11 13 19 26) (5 11 13 29 34) (5 11 15 23 30) (5 12 26 26 39) (5 13 25 25 38) (5 13 27 29 42) (5 14 16 22 31) (5 14 20 30 39) (5 14 26 28 41) (5 15 17 19 30) (5 16 18 22 33) (5 16 28 28 43) (5 17 17 29 38) (5 19 23 23 38) (5 20 20 20 35) (5 24 30 30 49) (5 25 25 29 46) (6 6 6 6 12) (6 6 6 26 28) (6 6 8 15 19) (6 6 9 24 27) (6 6 12 15 21) (6 6 12 25 29) (6 6 18 30 36) (6 6 21 24 33) (6 7 10 16 21) (6 8 10 23 27) (6 8 15 30 35) (6 8 20 20 30) (6 9 10 12 19) (6 9 18 20 29) (6 9 18 28 35) (6 9 24 26 37) (6 10 13 28 33) (6 10 18 18 28) (6 10 22 26 36) (6 10 30 30 44) (6 11 12 18 25) (6 11 16 26 33) (6 12 12 24 30) (6 12 15 18 27) (6 12 17 30 37) (6 12 20 24 34) (6 12 21 30 39) (6 13 20 22 33) (6 13 24 30 41) (6 15 16 18 29) (6 15 18 28 37) (6 16 24 24 38) (6 17 18 24 35) (6 18 26 30 44) (6 23 26 28 45) (6 24 24 24 42) (7 7 7 7 14) (7 7 7 23 26) (7 7 17 17 26) (7 7 19 21 30) (7 7 23 23 34) (7 8 8 28 31) (7 8 16 16 25) (7 8 20 24 33) (7 8 28 28 41) (7 10 16 18 27) (7 10 20 26 35) (7 11 17 21 30) (7 11 19 25 34) (7 12 18 18 29) (7 13 13 17 26) (7 14 14 20 29) (7 14 14 28 35) (7 15 21 21 34) (7 15 21 27 38) (7 16 16 20 31) (7 17 17 23 34) (7 18 24 30 43) (7 19 25 27 42) (7 20 26 30 45) (7 28 28 28 49) (8 8 8 8 16) (8 8 8 13 19) (8 8 8 22 26) (8 8 10 16 22) (8 8 12 13 21) (8 8 14 24 30) (8 8 16 20 28) (8 8 16 29 35) (8 8 20 29 37) (8 9 10 14 21) (8 9 10 22 27) (8 9 18 30 37) (8 10 10 19 25) (8 10 11 26 31) (8 10 13 14 23) (8 10 14 27 33) (8 10 16 16 26) (8 10 21 22 33) (8 10 23 26 37) (8 10 26 29 41) (8 11 12 20 27) (8 11 16 20 29) (8 11 16 28 35) (8 11 20 28 37) (8 12 12 18 26) (8 12 16 25 33) (8 12 21 24 35) (8 12 23 28 39) (8 13 14 14 25) (8 14 17 26 35) (8 14 19 30 39) (8 14 20 28 38) (8 14 22 25 37) (8 15 20 20 33) (8 16 16 18 30) (8 16 20 24 36) (8 16 24 25 39) (8 19 20 20 35) (8 20 20 30 42) (8 22 25 26 43) (8 22 28 28 46) (8 24 24 30 46) (9 9 9 9 18) (9 9 15 17 26) (9 9 21 29 38) (9 10 12 30 35) (9 11 13 23 30) (9 11 15 27 34) (9 12 12 16 25) (9 12 18 26 35) (9 12 30 30 45) (9 13 17 19 30) (9 14 14 16 27) (9 15 15 25 34) (9 15 27 27 42) (9 16 20 28 39) (9 22 26 28 45) (9 23 23 25 42) (10 10 10 10 20) (10 10 10 22 28) (10 10 13 16 25) (10 10 14 30 36) (10 10 19 20 31) (10 10 20 25 35) (10 11 16 22 31) (10 11 20 30 39) (10 11 26 28 41) (10 12 13 26 33) (10 12 14 17 27) (10 12 15 30 37) (10 12 16 20 30) (10 12 19 22 33) (10 13 24 26 39) (10 14 16 17 29) (10 14 17 28 37) (10 14 18 26 36) (10 14 20 23 35) (10 14 21 28 39) (10 15 18 24 35) (10 16 18 29 39) (10 16 20 20 34) (10 16 22 23 37) (10 16 22 29 41) (10 17 26 28 43) (10 19 22 24 39) (10 20 25 30 45) (10 22 26 26 44) (10 22 28 29 47) (10 26 28 29 49) (11 11 11 11 22) (11 11 17 25 34) (11 11 19 29 38) (11 13 13 21 30) (11 13 23 25 38) (11 14 14 24 33) (11 17 25 27 42) (11 18 20 26 39) (11 19 21 29 42) (11 20 22 26 41) (11 21 21 21 38) (11 23 25 29 46) (11 24 24 24 43) (12 12 12 12 24) (12 12 12 23 31) (12 12 15 24 33) (12 12 16 30 38) (12 12 19 24 35) (12 12 24 30 42) (12 13 18 18 31) (12 14 21 30 41) (12 15 18 26 37) (12 15 24 24 39) (12 16 17 20 33) (12 16 28 29 45) (12 18 18 27 39) (12 18 20 24 38) (12 18 22 27 41) (12 18 29 30 47) (12 20 24 27 43) (12 23 26 26 45) (12 24 24 27 45) (13 13 13 13 26) (13 13 17 23 34) (13 14 14 20 31) (13 14 16 30 39) (13 14 18 20 33) (13 15 23 29 42) (13 16 20 20 35) (13 17 19 25 38) (13 20 20 20 37) (13 21 23 25 42) (14 14 14 14 28) (14 14 16 21 33) (14 14 20 27 39) (14 16 17 22 35) (14 17 20 22 37) (14 20 21 22 39) (14 20 23 30 45) (14 24 27 30 49) (15 15 15 15 30) (15 16 16 28 39) (15 17 25 25 42) (15 18 20 30 43) (15 18 24 30 45) (15 24 30 30 51) (15 28 30 30 53) (16 16 16 16 32) (16 16 16 26 38) (16 16 24 26 42) (16 16 27 28 45) (16 17 20 24 39) (16 18 20 28 42) (16 18 27 30 47) (16 20 20 25 41) (16 20 26 28 46) (16 21 24 24 43) (16 22 22 25 43) (16 26 28 28 50) (17 17 17 17 34) (17 19 25 29 46) (17 20 22 26 43) (17 22 24 26 45) (17 23 29 29 50) (18 18 18 18 36) (18 18 24 25 43) (18 20 25 26 45) (19 19 19 19 38) (20 20 20 20 40) (20 20 21 28 45) (20 20 25 28 47) (20 22 22 29 47) (20 22 26 29 49) (20 24 28 29 51) (20 25 26 30 51) (20 28 28 29 53) (21 21 21 21 42) (21 22 24 30 49) (21 28 30 30 55) (22 22 22 22 44) (23 23 23 23 46) (24 24 24 24 48) (25 25 25 25 50) (26 26 26 26 52) (27 27 27 27 54) (28 28 28 28 56) (29 29 29 29 58) (30 30 30 30 60)) > (extract-cubes list-list) '((1 1 1 1 2) (2 2 2 2 4) (3 3 3 3 6) (4 4 4 4 8) (5 5 5 5 10) (6 6 6 6 12) (7 7 7 7 14) (8 8 8 8 16) (9 9 9 9 18) (10 10 10 10 20) (11 11 11 11 22) (12 12 12 12 24) (13 13 13 13 26) (14 14 14 14 28) (15 15 15 15 30) (16 16 16 16 32) (17 17 17 17 34) (18 18 18 18 36) (19 19 19 19 38) (20 20 20 20 40) (21 21 21 21 42) (22 22 22 22 44) (23 23 23 23 46) (24 24 24 24 48) (25 25 25 25 50) (26 26 26 26 52) (27 27 27 27 54) (28 28 28 28 56) (29 29 29 29 58) (30 30 30 30 60)) >
Last edited by danbaron; 27-05-2011 at 01:12.
"You can't cheat an honest man. Never give a sucker an even break, or smarten up a chump." - W.C.Fields
Dan,
Speaking as a mind, fingers and PC collective, we think that you could use "We" or "One" or even use the passive tense but there is no more efficient word than "I".
Charles
::begin communication to the (mechanism labeled by the) identifier (ID), Charles::
This ID does not know for certain what that ID means, concerning, "fingers". This ID can only guess that it refers to (collectively) typing on the keyboard (which, this ID (regrettably) thinks is on the fast road to extinction). Elsewise (otherwise), this ID thinks the word must have a particular societal (cultural) slang meaning, about which, this ID is unaware.
Now, upon further rumination, this ID becomes more convinced that, "fingers", does in fact, refer to typing.
::end communication from the ID Dan::
Last edited by danbaron; 27-05-2011 at 07:27.
"You can't cheat an honest man. Never give a sucker an even break, or smarten up a chump." - W.C.Fields
Bob,
this forum use the following syntax highlighter code: http://alexgorbatchev.com/SyntaxHighlighter
At the following page it describes the double click selection: http://alexgorbatchev.com/SyntaxHigh.../whatsnew.html
I've tested it in every browser I could from IE7 to Opera to Chrome and here is working fine.
Can you please confirm at least double click for selecting all code box is working?
Ciao
Eros
www.thinbasic.com | www.thinbasic.com/community/ | help.thinbasic.com
Windows 10 Pro for Workstations 64bit - 32 GB - Intel(R) Xeon(R) W-10855M CPU @ 2.80GHz - NVIDIA Quadro RTX 3000
i don't know about the double click, this works well with me but after the syntax coloring appears on the page, sometimes it is delayed depending on web speed.
the best browser is opera for quickly show the syntax color. internet explorer sometimes delay the syntax color. any way the double click relief greatly from dragging the mouse over the code.
I use mainly Chrome because its Javascript engine is almost 20x faster than any IE up to IE8 and at least 2x faster that IE9. I also like very much Chrome because it is updated every 2 weeks while you never know when IEx is updated during Windows Update process.
Firefox Javascript engine is quite fast, Opera is sometimes in the middle between Chrome and Firefox.
IE9 is quite good but M$ has decided it is only for Windows 7 while other browsers, even if more advanced than IE9, work also on Windows XP
If you cannot install IE9 because you are under XP I strongly suggest you to change your browser.
www.thinbasic.com | www.thinbasic.com/community/ | help.thinbasic.com
Windows 10 Pro for Workstations 64bit - 32 GB - Intel(R) Xeon(R) W-10855M CPU @ 2.80GHz - NVIDIA Quadro RTX 3000
I just now tried it with posts 1, 2, and 13.
It all works well, after a two or three second delay.
Thank you very much, Eros!
Regards,
Bob
P.S. I tried to change my profile to write a signature, but I couldn't find the setting.
Sorry for being a complainer.
Bookmarks