Dave W Thu, 19 Jan 2006 16:21:54 -0800
It was two stupid mistakes: 1) forgot to set the value of v[k + max] to x after the code block that increments x and y 2) a[x + 1] and b[x+ 1] should not be adding one to the index (algorithm is 1 based)