Find the sequence.
1
11
21
1211
111221
??????
Also explain the logic.
Right answer!
Find the number.
Let the number be x.
If x is divided by 1 the remainder is 0.
if x is divided by 2 the remainder is 1.
if x is divided by 3 the remainder is 2.
and so on..
till
if x is divided by 10 the remainder is 9.
What is the value of x ?
White plays first. This is possible when white makes a move with knight.
For example,
White knight moves from g1 to h3,the black pawn move from e7 to e5, again the white knight moves from h3 to g1.
sUccess cannot be spelled without u.
It gives those errors because you didn't change the prototype for sort_surname()
The prototype should be
void sort_surname(char**);/* not that the parameter Acc[] is not given*/
I guess you meant
C Syntax (Toggle Plain Text)
char *account_array;
Yeah, sorry that's due to my poor typing.
In your code the declaration of the pointer account_array is fine.
char (account_array[size];
Your function declaration is also fine.
void sort_surname(char *account_array[])
The mistake lies in the function calling in line 51.
sort_surname(number, *account_array);
Here you have passed structure, but in your function you didn't have any parameter to get structure.
So it should have been
sort_surname(account_array);
Give some object in the declaration.
For example..
sort_surname(ACC obj[],char *account_aray);
But i see that you are not using the any object in the function sort_surname(). So remove the parameter in the declaration and don't pass any structures in line 51.
case 2:
sort_surname(account_array);//not the number parameter
break;
In the function ..
void sort_surname(char *account_array[]);
Hope this helps.
In line 97 it seems that you have removed the parameter for structure, but you are passing a structure in the line 51. Check that out.
can you post the modified code?
It's giving that error because *account_array is not declared in main(). Keep in mind that the parameter is *account_array[]. So you should declare it appropriately.
Right answer!
Yes, in the switch case function an array is not passed as a parameter sort_surname ( number, /* *string */ );
And in the function definition of sort_surname object has not been declared. I wonder how come you haven't got any errors?
void sort_surname(ACC,char *account_array[])//here the object should have been declared
You should have made a discussion thread not a poll.
Hello drongo,
In your function calling you didn't mention all the parameters. You didn't give the char* parameter.
Hello Labdabeta,
I hope you are asking to convert the string into integer(binary number) and then converting it to decimal. If yes,try this one..
For example, if there is '1' in a[0] then subtracting a[0] and '0' will give 1.
int b;
char a[100];
b=a[0]-'0';
The ASCII value of '1'(which is 49) is subtracted with ASCII value of '0'(which is 48).
Do this in a loop. Then you will have the binary number. Convert it into decimal.
So far this is what i have and i am stuck because i do not know how to find when the derivative goes from negative to positive or from positive to negative.
You need to store some data(altitude and time) in change.dat when velocity becomes negative. I htink this is what you are trying to do?
correct me if i am wrong.
The second thing is , in line 20 you have given derivative[lcv] = deltaT[lcv]/ deltaZ[lcv]; which contradicts the expression you posted (v= z/t)
Hello ghostmonkey,
In line 19 you didn't assign the value. You have used == . Is that a mistake due to your typing ? Why can't you use another integer array for storing zeros and a variable to count the number of zeros ?
Maybe the person came to that place after the bomb blast ?
Yeah WaltP, i tried replacing the required font in the existing default one as you said. I just got a small shaded rectangle.
I know the value that is returned by registerfarbgifont() should be used in outtextxy(). But i always get -13 given by registerfarbgifont(). That's where my problem lies.
Be the change that you seek - Mahatma Gandhi
It's not a*a*a i think. Triple means a * 3.
That's what i said in my previous post. Count is bound to main() only you cannot use it elsewhere and count1 can be used in the tripecallbyvalue() function only. So you should modify the lines 7 and 8 like this..
cout<<"count is "<<count<<endl;
cout<< "count1 is " << tripeCallByValue(count);
and line 10 in the function tripeCallByValue() like this...
count1 = count1 * 3;