King David (probably) went to heaven. That was in spite of the fact the he committed a number of sins, the most egregious of which was stealing Bathesheba from Uriah.
The some is probably true of his son King Solomon.
David wrote the book of Psalms, and Solomon the books of Proverbs, Ecclesiastes, and Song of Solomon. That shows that they thought a lot about God, Jesus, and right and wrong.
Then there was the story of the prophet (I believe it was Daniel) who "mediated on the law day and night."
All other things being equal, are people that "think a lot about" God more likely to go to heaven than people who don't? Put another way, would another king who committed "Bathesheba" and other similar sins but don't "think a lot about" God be more likely to go to Hell than King David?