Not sure this helps:
]n=:(8#256) #: 81985529216486896x
1 35 69 103 137 171 205 240
Note the 240 in n
_3 ic |.n{a.
81985529216486896
On 4/25/2018 10:29 AM, Thomas Hickey wrote:
I have a 64 bit number:
16b123456789abcdef = 81985529216486896
encoded in 8 bytes in a file:
239 205 171 137 103 69 35 1
but
_3 ic 239 205 171 137 103 69 35 1 { a. returns 81985529216486895 (1 less
than I expected)
16 #.inv 81985529216486895 returns 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
16 #.inv 81985529216486896 returns 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 0
I suppose this has something to do with signed 64 bit integers, but I don't
understand it. I'm running on a Intel machine (Surface laptop).
--Th
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm