From Why Not Eat Octopus?, by Silvia Killingsworth:
‘Octopus intelligence is well documented: they have been known to open jars, guard their unhatched eggs for months or even years, and demonstrate personalities. Most famously, they can blast a cloud of ink to throw off predators, but even more impressive is the masterfully complex camouflage employed by several members of Cephalopoda (a class that also includes squid and cuttlefish). Their curious behaviors are also culturally familiar. Ringo Starr traces the origins of his song “Octopus’s Garden” to an anecdote that a sea captain once told him in Sardinia, about the habit octopuses have of adorning their homes with rocks and detritus. […] With their ovoid, head-like mantles, octopuses even look the part. They have relatively large brains, three hearts, and a decentralized nervous system that confers incredible motor dexterity—and they can squeeze through any opening larger than their beaks. They’ve been observed to “walk” on the ocean floor and even dry land. They have remained inscrutable in part by being notoriously difficult lab animals. There are stories of them unplugging drains, disconnecting wires, and resisting the maze challenge. They are known to possess around five hundred million neurons—which is not such an impressive number when compared with the eighty-six billion in the human brain, but is notable for the fact that more than half of them are located in the animal’s arms. I like to think of an octopus as a blobby, eight-fingered hand, but with a mind of its own and the uncanny ability to change color, size, shape, and texture. And then I’m suddenly not so keen on the idea of eating it.’
See also Deep Intellect by Sy Montgomery.