Che-mysteries!
The same way he solved all other problems: He worked it out with a pencil and paper.
A pirate aye!
Because they research everything.
HeHe