How do I stop comparing myself to others?

I always have this problem of feeling inadequate. I’m a junior CS student at a decent but not great school. Some of my friends go to Stanford or UT Austin and have already interned with multiple top companies, while I haven’t accomplished anything of significance… I’m really impatient to achieve big things. It’s like I need to in order to justify my existence. How do I transition to a healthier state of mind and stop feeling worthless?