John invites believers having the wisdom to “interpret scripture with scripture” solve the riddle of 666 meaning. That is confirmed by the parallel to “Here is wisdom” ωδε ἡ σοφία ἐστίν in Revelation 17:9, “here the mind which has wisdom” ὧδε ὁ νοῦς ὁ ἔχων σοφίαν. Just as the “mind which has wisdom” solves the riddle of the “seven heads” being both “mountains” and “kings” using Old Testament Scripture, so do believers solve John’s riddle.
Here is wisdom. Let him that hath understanding count the number of the beast: for it is the number of a man; and his number is Six hundred threescore and six (Rev. 13:18 KJV)
John gives three clues: 1) “Counting” reveals 666 IS the number of the Antichrist Beast; 2)”Counting” that results in 666 reveals it is the “number OF a man”. 3)The number 666 is the Biblical allusion identifying the Old Testament scriptures necessary to solve the riddle.
The children of Adonikam, six hundred sixty and six. (Ezr. 2:13) KJV
The children of Adonikam, six hundred threescore and seven. (Neh. 7:18) KJV
John’s riddle is based on BOTH 666 and 667 being correct. The different counts arise because both Father and son are named Adonikam:
Ezra counts Firstborn Adonikam’s children, therefore 666 is “the number OF a man” because generating 666 children brought the number into existence. Nehemiah’s count of Father Adonikam’s children includes his firstborn Adonikam, so his children total 667.
Hence, 666 is the Janus pivot that reveals the “number of the Beast as we “count” (5585 ψηφίζω psephizo), and his name “Adonikam”.
Counting backward from Adonikam’s father, we deduce 666 number is OF the Beast because when we count as with pebbles from Father Adonikam (667-1=666) “his (the Beast’s) number is 666”. Counting forward reveals the number itself comes into being because of firstborn Adonikam, a count of his children is 666. So it is “the “number OF a man”
Whether we count forward or backward the name Adonikam appears. Therefore, name of the Beast is Adonikam.
So the riddle is solved just like other Biblical riddles, double entendre and allusion reveals the answer. 
This “forward/backward” pivoting on 666 is a Janus Parallelism common in the Old Testament (Gen. 6:3; 49:26; Cant. 2:12; Ezek. 20:37; Dan. 11:35; Nah. 1:8).
Janus Parallelism. This type of parallelism hinges on the use of a single word with two different meanings, one of which forms a parallel with what precedes and the other with what follows. Thus, by virtue of a double entendre, the parallelism faces in both directions. Berlin, A. (1992). Parallelism. In D. N. Freedman (Ed.), The Anchor Yale Bible Dictionary (Vol. 5, p. 157). New York: Doubleday.
Although knowledge of Janus Parallelisms was lost until Hebrew expert Cyrus Gordon rediscovered them in 1978 (New Directions, BASP 15, pp. 59-60), the apostle John being an expert in Hebrew Scripture would be familiar with them.
[This author also interprets “Matthew 16:18 petros as a Janus “pivoting on the Greek and Aramaic meanings of πέτρος “stone” (cf. Mk. 3:16-17; John 1:42) and פטרוס “First, firstborn” (cf. Mt. 10:2; John 1:40), cf. Hebrew 06363 פֶּטֶר peter.]
Double Entendre and misdirection of outsiders
Let’s review Samson’s riddle, it reveals a blueprint for solving Biblical riddles. An important clue is the double meaning of the words “lion” and “honey” in the language of Samson and the Philistines:
The word “lion” in Hebrew (ʾarî) is almost identical to an Arabic word for “honey” (ʾary).-Wolf, H. (1992). Judges. In F. E. Gaebelein (Ed.), The Expositor’s Bible Commentary: Deuteronomy, Joshua, Judges, Ruth, 1 & 2 Samuel (Vol. 3, p. 468). Grand Rapids, MI: Zondervan Publishing House.
So he said to them: “Out of the eater came something to eat, And out of the strong came something sweet.” Now for three days they could not explain the riddle. (Jdg. 14:14) NKJ
“Eater” in Hebrew can be a man, beast or insect that “devours with extreme violence” (0398 אָכַל ‘akal Num. 23:24; 1 Ki. 13:28). As the “eater” is “strong” (05794 עַז `az) “mighty, fierce” the image of lion naturally arises. Confirming this describes a lion is the irony of taking food from the lion’s mouth, a definite clue.
As for “sweet” honey naturally comes to mind (Jdg. 14:18).
The “lion/honey” homonym is what made this a valid riddle. Notice these points are present in the answer the Philistines gave to Samson:
What is sweeter than honey? and what is stronger than a lion? (Jdg. 14:18)
Many commentators object the riddle was unfair, but the context contradicts that claim. They wouldn’t have wasted three days trying to solve it, or by the seventh day threaten the bride’s family if they could have simply objected it wasn’t a fair riddle (Jdg. 14:14-15). Their answer in Judges 14:18 implies they considered it fair, the answer a valid result of the clues in the riddle.
What likely prevented the Philistines from solving the riddle was the presence of many possible “strong eaters” and “sweets” at the feast. That would misdirect their attention away from the solution.
They broke the first rule for solving riddles, thinking outside of the box is a must.. The accidental context is likely irrelevant, and the choice of some words like “count” (ψηφίζω) specially chosen to “misdirect” the uninitiated to the wrong solution, as it does to modern scholars who suppose occult Gematria of Jewish Mysticism is pertinent to the solution. That parallels their reliance upon the apocrypha and pseudepigrapha, which at best are Satanic disinformation. From this evidence the soundness of sola scriptura and dependence on the “Received Text” is proved, but they do not see it.