When I was younger, for whatever reason, I found myself repeatedly in places that knowing nothing of the subject, the people next to me with years of experience were so incompetent that I could surpass them with a little bit of thought.
I view intelligence in three parts: Confidence, Drive, and plain old Intelligence. The confidence side of my intelligence has always been pretty high. However, I've found a lot of people with heaps of intelligence, but not the drive to do anything with it, or maybe not the confidence to move, even if they want to.
Fast forward to now when I'm working at a company in which everyone knows their role quite well, it's been very humbling. I've found I can't just walk in the room and start making things better. Because they are good at what they do, I can no longer do that. If I want to contribute, I have to work long and hard to figure out how to improve things. And what looks better to me actually may not be better in all or most ways, considering more perspectives.
With this, I suspect that those who have grown up with incredibly smart people around them, while maybe being equally intelligent, feel more inferior. And those who grow up and find themselves often in areas that they can rapidly iterate without effort, quickly feel confident.
The interesting thing is that the confidence can very quickly grow into further intelligence. Or just lead you to be obnoxious and cocky, of course.