I haven't finish this program, but i got an error during compiling.(I try to get one part of the program working...)
i don't know why.
Please help
I haven't finish this program, but i got an error during compiling.(I try to get one part of the program working...)
i don't know why.
Please help
here is one of my problem(the error) with this program, i don't know how to...well i don't have a word for that, therefore i can show you an example here:
i have no problem to create a simple function like this...
function prototype
int main()
{
int number;
char word;
...
...
....
}
void Calculatething(int number, char word)
{
...
}
but i have problem with that:
function prototype
int main()
{
typedef string [30];
string name[100];
int number;
....
}
void Calculatething(int number, ??? name)
{
...
}
hope you guys understand my bad explanation....
my best guess is when you declaired your variable defined it like this: char name[100][30]; in your function, youre only passing in a char [], basically, you created a two dimensional array and are trying to pass it into a function that is accepting a one dimensional array
hope i didnt lose ya
guns dont kill people, abortion clinics kill people.
unfortunately, my teacher didn't start teaching the "real" 2 dimention array "arr[] []" form.
so i have to use the "typedef", so how can i pass to the function?
u have a nother file that u open?
it will work if you change the typedefs to plain chars like this
int choice=0;
int num[100];
int length1;
char namestring[30];
char name[100];
char last[100];
char string[10];
char gend[100];
char pass[20];
then on your pass
use cin.getline()
well...
my teacher said to use typedef....
anyway, here is my .txt file that the program will open..