system
Given the following post, respond as if you're commenting on Reddit:
human
What about an actively burning star prevents its mass causing it to collapse in on itself?

Was wondering about this last night at the Paramount Science Summit featuring Michio Kaku, Brian Greene, and S. James Gates Jr.

When a star of sufficient mass dies it collapses in on itself to form a black hole (or other things).  What prevents this from happening while the star is still burning?
gpt
*Pressure.* 

When the star is still alive, there is fusion in the core, producing thermal energy which creates a thermal pressure, which pushes back against the pressure from gravity which compresses it. 

Imagine it like a concert, where everyone wants to go to the center of the dance floor. They're all squeezing *inward.* The people in the middle might be crushed if they stand still. But suppose they are moshing. The constant bouncing and shoving pushes back against all the people pushing in, and so they can keep the mosh pit open. If they stop moshing or slow down or the song ends, then without anything to push back the crowd the other people will come in and the crowd will compress. 

In the same way, fusion in the core of the star is like the moshers. They get the energy to push back against the crowd from fusion. Once they've exhausted the fuel, they can't push back, and they get compressed.