Quick answer
The fool is not in doubt. That is the problem the verse is naming, and it is why the second line makes listening the whole of wisdom.
Read both lines
The first line describes a state that feels identical from the inside to being right, which is what makes it dangerous and what makes it hard to talk anyone out of. Certainty is not the same as accuracy, and this book never treats confidence as evidence. The second line's answer is modest: not brilliance, not a superior instinct, just heeding counsel. That is the same recommendation 11:14 made about a multitude of counselors, and it rests on the same assumption, that any one person's view of themselves is the least reliable view available.
Related: Proverbs 11:14 · Proverbs 3:7 · Proverbs 26:12
New King James Version®, Copyright © 1982, Thomas Nelson. All rights reserved. Full copyright information. Scripture provided by API.Bible.
Go Deeper
If this verse has been used to put weight on you that it was never carrying, ask about it directly.