In the letter, Hamlet says that his ship was captured by pirates, who have returned him to Denmark. ... Horatio takes the sailors to the king and then follows them to find Hamlet, who is in the countryside near the castle. Hamlet becomes increasingly erratic in his behavior. This causes quite a bit of questioning on Hamlet's sanity. His lack of avenging his father's death has turned into despair. His reluctance to act is lessening by the end of act IV, and in act v he will be ready, at last.