I'm not sure how you define a palindrome integer, but none of the example given identify 090 (which is the same as 90) as being a palindrome. I'm not sure weather or not this is correct.
-EdK Ed Keith [email protected] Blog: edkeith.blogspot.com --- On Sun, 6/28/09, Sherlock, Ric <[email protected]> wrote: > From: Sherlock, Ric <[email protected]> > Subject: Re: [Jprogramming] tacit example ? > To: "Programming forum" <[email protected]> > Date: Sunday, June 28, 2009, 8:22 PM > > > > From: Sherlock, Ric > > > From: Saunders, John (Health) > > > > > > Hello I have the below line to test if an integer > is a palindrome but > > > couldn't work out how to do this tacitly could > anyone kindly provide > > > a tacit example ? > > > > > > > > isPalin0=: = |.&.": > > isPalin1=: (-: |.)@": > > > > If you want to test a vector of integers, then you'll need > to use "0 or this version: > > isPalin2=: (-: |.)&>@(8!:0) > > isPalin2 134431 45544 > 1 0 > isPalin2 134431 4554 > 1 1 > isPalin0"0 ]134431 45544 > 1 0 > isPalin1"0 ]134431 45544 > 1 0 > > ---------------------------------------------------------------------- > For information about J forums see http://www.jsoftware.com/forums.htm > ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm
