Hi there,
I am trying to seach through a sorted linked list using the binary search algorithm. My situation is I have the structure
the this linked list is currently sorted against the char *key value casted into int. My question is, is this a vailid way to sort (casing a char array into int); I was wondering if "AABB" will have a same value as "BBAA" ?
I am trying to seach through a sorted linked list using the binary search algorithm. My situation is I have the structure
Code:
typedef struct node
{
char *key;
int index;
struct node*nextphrase;
}
the this linked list is currently sorted against the char *key value casted into int. My question is, is this a vailid way to sort (casing a char array into int); I was wondering if "AABB" will have a same value as "BBAA" ?