Launch command by clicking words at the chat

Solution 1:

You would use the /tellraw command to do this. Using the command:

/tellraw @p ["",{"text":"Yes ","color":"green","clickEvent":{"action":"run_command","value":"/tp @p x y z "}},{"text":"No","color":"red","clickEvent":{"action":"run_command","value":"/tp @p x y z "}}]

This would display text in chat "Yes No", where the Yes is green and the No is red. In the command where you see the first "/tp @p x y z" (does not need to be a tp command, of course) put whatever coordinates you want to tp the player to if they click on Yes. Do the same thing for the second "/tp @p x y z" for if they were to click on No. You are also able to add more text after or before the "Yes No".