Hi , i need to calculate an expression with +/- only , it will get result once it see '=' sign using stack linked list (for exp: 200-100=) ,result 100. (multi digit needed)
My code is not...
Type: Posts; User: Bexita
Hi , i need to calculate an expression with +/- only , it will get result once it see '=' sign using stack linked list (for exp: 200-100=) ,result 100. (multi digit needed)
My code is not...
Thanks I changed VoidPtr target to char terget , worked...:D
int compare(VoidPtr vp1, VoidPtr vp2){
char i = *(static_cast <char*>(vp1));
char j = *(static_cast <char*>(vp2));
if (i==j)
return 0;
else if( i<j)
return -1;
I moved return found out of the loop , but still got error for the line if (here->next ==target).
Because I declare target as VoidPointer as requirement , This is what I'm stucking...
Hi,
I wanted to search an element (char) in the list S, but everytime it said that 02x is not in S
How to declare char target in a manner way? i think its my mistake for this code.
Thanks.
...
Thanks, my mistake lol...
Hi ,
I'm not sure how to proceed next . Can you enlighten me?
Thankss
Hi,
I changed a litte bit, but it doesnt work for me ...still only found the first element...
bool Search(char *a, int size, char *which) // Search element
{
Ptr b= a;
int flag =0;
Hi,
I have a array string such as a set
S= {W,P,A,Z}
I only manage to search the first element which is W , but not for others ( it will say not found if i search for P, for instance),...