A happy ending is very satisfactory for the reader. The hero or protagonist lives happily ever after and the villain gets what's coming to him. Things that were lost are found and obstacles are overcome. The hero saves the world from catastrophe, and the couple gets their kidnapped child back.
At the end of a tragic novel, the hero or protagonist often dies. The ultimate problem in the story may be resolved, but it is at the hero's expense. Although the ending is tragic, characters in the story often learn valuable lessons and will be better people as a result.
A novel that has a twist ending surprises the reader with the unexpected. This type of ending is most common in mysteries. The person who committed the crime is often the last person you would expect, or the situation is not quite as it appeared. It takes skill to write a twist ending. If done incorrectly, the reader might feel cheated.
An ambiguous ending leaves it to the reader to interpret the end of the story. The author chooses to leave some of the main storylines unresolved. The reader is free to imagine what happens in the lives of the characters, such as whether the bad guy got away or whether their favorite couple ever got married. However, many readers don't appreciate this type of ending.