Answer:
Hamlet devises a plan to test the Ghost's words.
after the players arrive at the castle,
Hamlets plan is to have them play out a scene that is surprisingly identical to that which the Ghost described of Claudius.
If Claudius gets nervous in any way,
Hamlet would know that it was true.
hope this helps :)