There was some discussion of the case n=3 in sci.math around 1994. There is a card game called Set with an 81 card deck so that each card is naturally a point in $(\mathbb Z/3)^4$. Several cards are dealt out, and your task is to identify triples of cards called Sets which form a line, or equivalently, which add up to the 0 vector. A natural question is how many points you can deal out without the existence of a line. It's not too hard to construct 9 distinct points in affine 3-space, or 20 distinct points in affine 4-space over $\mathbb Z/3$ so that there is no line contained in the points, and these are the maximums. These correspond to $N=19$ for $(n,k) = (3,3)$ and $N=41$ for $(n,k) = (3,4)$, as in the reference Ricky Liu linked, by repeating each point twice.

The maximal configurations are highly symmetric. The 9 points in dimension 3 correspond to a nondegenerate conic, which is unique up to symmetry. The 20 points in dimension 4 actually correspond to a nondegenerate conic containing 10 points in projective 3-space viewed as lines passing through the origin in affine 4-space.

For example, there are 9 points in dimension 3 satisfying $z=x^2 + y^2:$
$\{(0,0,0),(\pm1,0,1),(0,\pm1,1),(\pm1,\pm1,-1)\}$
and this set contains no lines.

`n-1`

subsets summing to 0 vector, which explains why the problem is about size`n`

subsets. $\endgroup$ – Ilya Nikokoshev Dec 5 '09 at 23:54