Well that’s simple, because the person doing the shoving is acting first. There are many push or fold calculators or just ranges depending on how many big blinds you have, the action that preceded you (although this is often not included and is more of an experience thing I think) and the amount of player to the left of you.
Check them out.