This question seems similar to the question about Modim for which there are four answers, but none of those answers fit here. In particular, the trope is the same on both phrases. This is clearly not a gender swtich, nor a pausal. So what causes the switch? Thanks.
In both cases the mark on the word לך is a tipcha, but that tipcha is more "powerful" the second time and hence is more prone to inciting a pausal vowel form.
Pausal cantillation marks each divide a verse-segment in half. That verse segment begins after the preceding mark of equal or higher strength and continues until the following mark of higher strength. Tipcha is a second-order note (along with zakef, segol and shalshelet) and etnachta is a first-order note (along with silluk).
Accordingly, the segment being divided by the tipcha in the first verse is נתן לך - נחלה while the segment being divided by the tipcha in the second verse is ולקחת מראשית כל פרי האדמה אשר תביא מארצך אשר יהוה אלהיך נתן לך - ושמת בטנא. In that sense it is not surprising that a pausal vowel form is more likely to show up in the second verse.