OK, I am writing a code that deals with American Football and the down and distance. What I want it the computer to do simple calculations of the down and distance. If you do not know football all to well, you may not be able to help.
I basically have it set up like this, there are 5 things that can happen on a play: a "gain", a "loss", an "int", a "fumble", and a "punt". But as you will see, the program asks the user for 3 pieces of input, "gainOrLoss" which asked which of the five happened, a string for the word "of", and an integer("gainLoss") for the amount of yards gained or lossed. What I would like the program to do if the "gainOrLoss" is "punt, int, or fumble" is give the output a first down and restart. I know the answer is right in front of me but I am struggling to grasped the logic/syntax of the issue. Any suggestions would be appreciated. Here is my code, there are some random cout's that tell me where the program is, you can ignore those: