Hi guys,
Can anyone see where I'm going wrong with this, I'm hopeless with C so considering I'm dong a module on it i'm struggling.
I've not compiled them but I've got a feeling theyre wrong.Code:boolean wordLess(wordADT word1, wordADT word2) { if (isNull(word1)==FALSE) { if(isNULL(word2)==FALSE) { if(word1->data)<(word2->data)) \*if word1 is before2*\ { return TRUE; } else if(word1->data)==(word2->data) \*if if first letter is the same, check the next letter*\ { return wordLess(word->next,word2->next); } else { return FALSE; } else { return FALSE; } } } boolean wordEqual(wordADT word1, wordADT word2) if (isNull(word1)==FALSE) if(isNULL(word2)==FALSE) if(word1->data)==(word2->data)) return TRUE; else return wordEqual(word->next,word2->next); else return FALSE; else return FALSE;
Cheers guys */



LinkBack URL
About LinkBacks


