homework 6 submission

You forgot to handle the case of r->k == k
In that case, just change r->data to the new value