Let's say I want to target the nearest player to 5, 5, 5 and teleport them to 50, 50, 50:
/tp @p[x=5,y=5,z=5] 50 50 50
but then I want to
/kill them (specifically in this order). This would not work:
because there may be another player there that is different.
How do I remember who I selected first to target them in multiple commands?