I saw that function and didn't look twice at it. Thank you so much!
Type: Posts; User: Shawty
I saw that function and didn't look twice at it. Thank you so much!
Ok... I know how to get a substring using the variable type "string," BUT... how do I get a substring of an array of characters.
For instance, if I have a character array of size 9, how do I pull...
I would try to figure out the whole problem, but I'm trying to work on my own program. One thing I do see that looks a little suspect is in this function:
long isInInventory(string...
I'm working on my program right now with strings. I tried to play with this command a little bit, but it might at least help you.
If you read in each like as a string, you can use the "find()"...
Ok. I can understand that. I did it by accident and just wondered why it worked. I'll stick with "strcpy" to be better safe than sorry.
Thanks you two!
When you use the word "pointer," I think of dynamic memory... linked lists... etc. I thought that was the only time you use pointers.
If my assumption is correct, then that doesn't apply......
I inserted the following code into my program before I remembered what variable type I was using and it works:
void somefunction ()
{
char name[6][20];
char drop[20];
THANK YOU BOTH!
It is a little sloppy. In general, choice is the same as option. I mean to declare global variables: Names Male, Names Female, and int choice = 0.
I decided that might be easier so I don't have...
I guess what I mean is... as long as I call the RunOption() function under my class variable (like Male), can I assume that all functions called FROM the RunOption() function will make changes to...
If I have declared more than one variable of a "class" type I have already defined, how can I be sure which variable I am manipulating. If I have one function which uses "switch" to call functions...