Well, I HAD something I was going to report, but it sounds like you know about it already.
Type: Posts; User: Gabu
Well, I HAD something I was going to report, but it sounds like you know about it already.
You have a ">>" where it should be a "<<" there.
Wouldn't it be easier to take the "If you wish to translate another letter please type it and press Enter,otherwise press ESC to exit:" part out of the if/else/if/else/etc. bit and stick it below all...
Well, not necessarily, you could do this for numbers out of that range:
#include <iostream.h>
#include <stdlib.h>
#include <ctype.h>
int main()
{
You can't. A variable can only be one single type.
However, the numbers 0 through 9 still are characters, as well, so typing in a number would work with a character variable.
That means that the functions "prompt_gallons", "prompt_miles", "prompt_done", and "average" are not defined yet.
You could try this:
int fiveChosen; /* this would occur higher up, not right above what follows it here */
do
{
fiveChosen = 0;
Oh, I get it.
No, cin by itself doesn't do that, but you can use the function cin.get() to do that.
Just add this:
cin.get();...where you want it to do that.
Oh, and if the program...
Please elaborate; I can't think of a case where cin doesn't wait until enter is pressed.
I see the problem, you declared "human" with the following line:
Player human();
Leave out the () part; those are only there if you are not using a default constructor and instead are using...
First error:
You're declaring multiple classes like multiple variables. You can't do that; I have a feeling you didn't mean to use "class".
Second error:
You either missed a variable type,...
Such supportive and loving parents! :p
"I AM NOT dividing."
To get the remainder, first you must divide. Modulus does that; therefore you ARE dividing.
Plus, even if it didn't, what's the remainder when dividing by zero? It'd...
Three things:
1. I believe the segmentation error came from the fact that you used a forward slash after "c:" instead of a backward slash, because it worked after I changed it to a backward slah....
I'm a bit shaky on how the "shuffle" and "deal" functions work regarding shuffling your deck and dealing five cards. If you could explain in plain English what's happening there, I might be able to...
I wasn't sure whether to post this in the game programming forum or this one, but because it's more of a technical thing, I'm posting it here.
Here's my problem. I'm making a text-based RPG, and...