Last chance for gas

Wrote if statement and else statement for this problem. about to
comment my thoughts into code