for n, there is the simpler: n =. ; cutLF wd 'clippaste'
after selecting and copying from project euler site. ----- Original Message ----- From: Linda Alvord <[email protected]> To: [email protected] Cc: Sent: Friday, July 4, 2014 11:14:53 PM Subject: Re: [Jprogramming] Project Euler Problem 8 OOOPS. I forgot n n=:A,B,C,D,E,F,G,H,I,J,K,L,M,N,O,P,Q,R,S,T Linda -----Original Message----- From: [email protected] [mailto:[email protected]] On Behalf Of Linda Alvord Sent: Friday, July 04, 2014 11:04 PM To: [email protected] Subject: Re: [Jprogramming] Project Euler Problem 8 Here's my try at this. A=:'73167176531330624919225119674426574742355349194934' B=:'96983520312774506326239578318016984801869478851843' C=:'85861560789112949495459501737958331952853208805511' D=:'12540698747158523863050715693290963295227443043557' E=:'66896648950445244523161731856403098711121722383113' F=:'62229893423380308135336276614282806444486645238749' G=:'30358907296290491560440772390713810515859307960866' H=:'70172427121883998797908792274921901699720888093776' I=:'65727333001053367881220235421809751254540594752243' J=:'52584907711670556013604839586446706324415722155397' K=:'53697817977846174064955149290862569321978468622482' L=:'83972241375657056057490261407972968652414535100474' M=:'82166370484403199890008895243450658541227588666881' N=:'16427171479924442928230863465674813919123162824586' O=:'17866458359124566529476545682848912883142607690042' P=:'24219022671055626321111109370544217506941658960408' Q=:'07198403850962455444362981230987879927244284909188' R=:'84580156166097919133875499200524063689912560717606' S=:'05886116467109405077541002256983155200055935729725' T=:'71636269561882670428252483600823257530420752963450' f=: 13 :'>./*/"1 (5#10)#:".":"1 |:((i.5)+/i.996){y' f n 40824 Linda -----Original Message----- From: [email protected] [mailto:[email protected]] On Behalf Of mvillarino Sent: Friday, July 04, 2014 1:46 AM To: [email protected] Subject: Re: [Jprogramming] Project Euler Problem 8 Thanks a lots!, Now i'll study this over the next week ! > >./ 13 */@:". \ n > > > (#~ ( 13 = '0' i.~ ])"1) 13,\ 40{. n > turns out I was wrong and it is faster to filter out the 0s! Same happens for problem nr 4, that of the maximum palindrome with five or six figures recently discussed. If you filter out mulitples of 10 from the initial 100+i.900, as they render products ending by nought, resulting expression is some nineteen percent faster. ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm
