that depends on field position, how good/bad your defense is, how good your kicker is, has your offensive line shown that they can get a push.
theoretically if you have a good running back and a line that can push open gaps you could run the ball all day. only need 2.5 yards avg and you are golden, but it doesn't work that way
yes, there are times where taking 4 downs to get a first down is a good idea, but punting is not the worst decision.