The primary purpose of this excerpt is to entertain.
This excerpt is was taken from "The Crab That Played with the Sea” by Rudyard Kipling. Generally, the main purpose of a piece of literature is to entertain the reader. In other words, what a person that writes fiction always tries to do is providing the reader with an entertaining story. An author can also have another purpose besides entertaining, such as persuading; however, it is not the case of Kipling with "The Crab That Played with the Sea", which was written to entertain mainly young readers.