Hacker News new | past | comments | ask | show | jobs | submit login

Thank you, I was wondering about the purpose of the tr function, which calculates the product of all elements in the vector, now it's clear that it goes from the array of lengths in each dimension to the total "flat" number of elements.

So the "r" field in the "a" struct is the number of dimensions of the array that "a" holds, and the "d" field is the array that holds the length of the array "a" in each dimension.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact