How would I make a "select block" function

Like it said in the title, I am trying to find a block I am looking at, and save the cords of that block for later use. How would I do that?

Continue to help post