mytext = "Now is the time for all good men to come to the aid of their party";
Flatten[
Table[{i <> j,
Length[StringCases[mytext,
Shortest[WordBoundary ~~ i <> j ~~ __ ~~ WordBoundary]]]},
{i, CharacterRange["a", "z"]},
{j, CharacterRange["a", "z"]}],
1] // TableForm
Just replace mytext with your Hamlet text.
Here are the results for the First Act, up to Horatio's speech starting "That can I..."
{{"th", 65}, {"to", 23}, {"of", 22}, {"an", 21}, {"no", 14}, {"st",
12}, {"ha", 12}, {"yo", 11}, {"ni", 10}, {"it", 10}, {"he",
10}, {"so", 9}, {"ma", 9}, {"be", 9}, {"sp", 8}, {"wa", 7}, {"ki",
7}, {"co", 7}, {"wh", 6}, {"on", 6}, {"li", 6}, {"hi", 6}, {"go",
6}, {"wi", 5}, {"we", 5}, {"us", 5}, {"tw", 5}, {"se", 5}, {"ou",
5}, {"my", 5}, {"mo", 5}, {"ho", 5}, {"ca", 5}, {"ar", 5}, {"ag",
5}, {"si", 4}, {"sa", 4}, {"pa", 4}, {"mi", 4}, {"me", 4}, {"fr",
4}, {"fo", 4}, {"fa", 4}, {"do", 4}, {"ap", 4}, {"wo", 3}, {"ti",
3}, {"su", 3}, {"lo", 3}, {"le", 3}, {"la", 3}, {"is", 3}, {"in",
3}, {"gr", 3}, {"da", 3}, {"ch", 3}, {"bu", 3}, {"at", 3}, {"tr",
2}, {"ta", 2}, {"sc", 2}, {"re", 2}, {"qu", 2}, {"pr", 2}, {"po",
2}, {"pl", 2}, {"ne", 2}, {"kn", 2}, {"im", 2}, {"ey", 2}, {"di",
2}, {"de", 2}, {"by", 2}, {"br", 2}, {"bi", 2}, {"aw", 2}, {"am",
2}, {"al", 2}, {"ve", 1}, {"up", 1}, {"un", 1}, {"tu", 1}, {"te",
1}, {"sw", 1}, {"sm", 1}, {"sl", 1}, {"sh", 1}, {"ri", 1}, {"pi",
1}, {"ow", 1}, {"ot", 1}, {"op", 1}, {"ob", 1}, {"mu", 1}, {"ju",
1}, {"jo", 1}, {"il", 1}, {"if", 1}, {"ic", 1}, {"gu", 1}, {"ge",
1}, {"fi", 1}, {"fe", 1}, {"er", 1}, {"en", 1}, {"ea", 1}, {"dr",
1}, {"bo", 1}, {"av", 1}, {"as", 1}}