xy = {{x1, y1}, {x2, y2}, ...}
z = {z1, z2, ...}
xyz = Partition[Flatten[Riffle[xy, z]], 3]
and you're done. RiffleRiffle
also works with just one z-value,: it'll do exactly what your question wasyou asked, after re-reading your question more carefully.
Explanation:
First, Riffle[list1,list2 or element, so just z1 works, too]Riffle[list1, list2 **or** element, so just z1 works, too]
makes
{ {x1, y1}, z1, {x2, y2}, z2, ...}
then, Flatten[list(s)]Flatten[list]
makes
{ x1, y1, z1, x2, y2, z2, ... }
finally, Partition[list,n]Partition[list, 3]
turns it into
{ {x1, y1, z1}, {x2, y2, z2}, ...}