Please post your code here (using code tags), rather than a screen shot.
Line 55:
An "else" shouldn't shouldn't be followed by a conditional expression like that, it defeats the whole purpose of "else".
Code:
if ( /* expression */)
/* do something 1 */
else
/* do something 2 */
The same is true even if you use an "if-else" chain:
Code:
if ( /* expression 1 */)
/* do something 1 */
else if ( /* expression 2 */)
/* do something 2 */
else
/* do something 3 */
Lines 60 and 61:
Code:
scanf("%lf", &cho2);
if(cho2=='fight');
1. "cho2" is a double, you're reading it as a double, so why are you trying to compare it to a word?
2. If you want to use the word "fight" (which it doesn't seem you do), then it needs to be enclosed in double quotes to be a proper string.
A couple of other observations (I could probably tell you more if I had actual code instead of a screenshot):
- "rand()" is a function from stdlib.h, you shouldn't declare your own function with this name
- Use more descriptive variable names: things like "ack", "pts", "cho", "cho2", etc make it difficult to read your code. Using complete names ("attack", "points", etc) make your code easier to read and more self-documenting.
- If "cho" and "cho2" are doubles, why are you treating them as characters (e.g. comparing them to 'Y' and 'n')?
- You have semi-colons after some of your "if()"s - this is wrong.