And the prize for the sneakiest thing in the sea goes to...

Attenborough documentaries aren't just glorious examples of television, they're useful for scientists in that they document some of the most difficult behaviours to observe in the wild.

Last night Blue Planet II outdid itself, getting footage of an octopus outsmarting the aptly-named pyjama shark.

The octopus in question lived off the coast of South Africa in a kelp forest. She's quite a good little hunter.

But (classic Attenborough) she is also the hunted. Blue Planet II filmed the octopus being attacked by a shark, and she had two incredible strategies for dealing with it. The first was to choke out a shark which had got hold of her.

The octopus slides her tentacles into the pyjama shark’s gill to try and suffocate it#BluePlanet2 pic.twitter.com/JsUoeWxYbX — BBC Earth (@BBCEarth) November 26, 2017

The marine equivalent of shoving your fist down an attacker's throat. Once she'd got away from shark attack no.1 however she had to find a place to hide. This is the part that blew everyone's minds.

Using her tentacles she pulled pieces of shell debris to cover her body, creating a sort of armour plating. This confused the shark that came to investigate the strange, octopus-shaped pile, giving her enough time to jet away.

Funny – I also cover myself in shells to hide from people I want to avoid#BluePlanet2 pic.twitter.com/XFxLWViiDh — BBC Earth (@BBCEarth) November 26, 2017

See you later sucker! Seriously though how clever is that octopus? Here to answer is the internet.

So slick with it pic.twitter.com/4ITaSWSrJp — Kid Shyne (@itskidshyne) November 27, 2017

The Tony Stark of octopus. — Mike G (@MichiganMikeG) November 27, 2017

What a clever girl she was! #BluePlanetII — Original Bond Girl (@theponsfords) November 27, 2017

Smarter than trump. — OMAR PLUTO🍁 (@bluebloodchild) November 27, 2017

welp, won't be long til they become smart enough to whip our butts... i'm going to make friends with an octopus, bye.👋🏻👋🏻🐙🌊 — Tom Mack (@T__Mack__) November 27, 2017

Well, I for one welcome our new cephalopod overlords. They clearly have lots to teach us.