(This requires a mind that has wisdom.) The seven heads are seven mountains the woman sits on. They are also seven kings:
This calls for wisdom: Let the one who has insight calculate the beast’s number, for it is man’s number, and his number is 666.