The answer already provided is excellent on the specifics of the novel, so I am choosing to answer only to add something Noelle Thompson did not mention: the source of the novel's title. There is a famous poem, written in 1785, entitled "To a Mouse" by the Scottish poet Robert Burns. Part of the charm of this poem is that it is written in dialect, a thick Scottish brogue. The poem has the subtitle "On Turning Her Up in Her Nest with the Plough, November, 1785," so the poem in some sense tells the story of the poet's reflections upon life after he unintentionally ruins the life of the mouse by "turning up" her nest. However, what really matters to readers of Of Mice and Men is the closing two stanzas of the poem. Steinbeck clearly borrowed his title from the line, "The best-laid schemes o' Mice an' Men/Gang aft agley..." which is typically translated as "the best laid plans of Mice and Men often go astray." Thus there is a clear connection between the theme of the novel (plans don't always work out) and the title.
There is an important lesson to be learned about interpreting literature here: what does the author want you to think about based upon the title? Many titles are "borrowed" from other literature such as the Bible or Shakespeare's plays. Here, Steinbeck makes a thematic connection to Burn's poem. Robert Frost has a poem about death with the title "Out, out--" which is a line about death from Shakespeare's Macbeth. Faulkner borrows from the same speech in Macbeth his title for his novel The Sound and the Fury. Hemingway borrows his title The Sun Also Rises from the biblical "Ecclesiastes." The point is that when an author steers you to an earlier work by basing a title upon it, quoting from it in the epigraph, or referring to it in any way in the text, you should consider whether there is a thematic connection to be made between the two works!
First, you have to keep in mind that the ending of Steinbeck's Of Mice and Men is one of the most debated endings in American literature. Therefore, realize that different scholars will have different opinions on how the ending relates to the themes as well as how it affects George, Lennie, and the other characters of the novel. In this case, however, it is fairly safe to say that the ending of Steinbeck's Of Mice and Men affects George greatly in that he shoots his best friend, Lennie.
Let's set the scene in regard to specifics so that we can truly see how the ending affects George. Lennie has mistakenly killed Curley's wife, and a mob is out to get Lennie as a result. There will be no escaping the mob, but Lennie runs (right to the same pool of the Salinas River) and George catches up to him. They are, of course, at the place where George told Lennie to hide if there was any trouble. On the way, George steals a gun. Knowing that the mob will arrive soon and kill Lennie, George asks Lennie to, again, talk about their dream of owning a farm. As Lennie happily recites the dream, and without knowing what is going to happen, George shoots Lennie in the head, killing him instantly. When people arrive, George claims that he took the gun from Lennie and pulled the trigger. George and Slim walk off together, much as George and Lennie walk off together at the beginning of the book.
Now for the meat of your question: how does this ending affect George? First, the idealistic dream of the farm owned by Lennie and George is gone. Why? Because Lennie is gone. It is Crooks that doubts the dream first:
Nobody never gets to heaven, and nobody gets no land. It's just in their head. They're all the time talkie' about it, but it's jus' in their head.
Does this mean that the entire dream is gone? No. Some say that the ending shows that George might create this dream either alone, or with Slim. But the original Lennie/George dream of the farm that they talk about through the entire book has ended. Second, the ending affects George by afflicting him with grief. George's hand is severely shaking when he pulls the trigger to shoot Lennie. It was not an easy thing for George to do, but he wanted his true friend to die believing in the beautiful dream they had and not at the hands of ugly lynchers. Third, does the ending condemn George? No. Through his white lie of saying that Lennie was the one who had stolen the gun and George shot him out of compassion, George saves himself. Some say this is true loyalty to the end. Others say it is simply his method of securing the dream for himself in the future. (I tend to believe the former.)
In conclusion, what is ambiguous about the ending resides in the reasoning behind George's actions. Did he shoot Lennie out of love for Lennie? Did he shoot Lennie out of love for George's own dreams? Did he shoot Lennie out of his own want of happiness in his life? You can answer "yes" to any of these questions and be correct. That is the meaning of Steinbeck's Of Mice and Men's ambiguity.