Economists since the times of Adam Smith (1723-1790), looking at non-specific pre-modern societies as examples, have used the inefficiency of barter to explain the emergence of money, of "the" economy, and hence of the discipline of economics itself. However, ethnographic studies have shown that no present or past society has used barter without any other medium of exchange or measurement, nor have anthropologists found evidence that money emerged from barter, instead finding that gift-giving (credit extended on a personal basis with an inter-personal balance maintained over the long term) was the most usual means of exchange of goods and services.
Bartering is based on a simple concept: Two individuals negotiate to determine the relative value of their goods and services and offer them to one another in an even exchange. It is the oldest form of commerce, dating back to at time before hard currency even existed. (Learn more about how bartering evolved, read The History of Money: From Barter To Banknotes.)
Although, as a general case, a ship unlucky in falling in with whales continues to cruise after them until she has barely sufficient provisions remaining to take her home, turning round then quietly and making the best of her way to her friends, yet there are instances when even this natural obstacle to the further prosecution of the voyage is overcome by headstrong captains, who, bartering the fruits of their hard-earned toils for a new supply of provisions in some of the ports of Chili or Peru, begin the voyage afresh with unabated zeal and perseverance.