you could try implementing your own version of strcmp?
strcmp() maintains two pointers to char, one for the first string, one for the second - it compares the values of what the pointers point to (ie the value of the char currently being pointed to) - if this value is zero (i.e. equal) then it increments the pointers and compares the next pair of bytes.
otherwise it returns with either a positive or negative value.
as far as I know strcmp() will return positive or negative based only on the first pair of bytes.
Ahmm.. briefly how will i operate the program correctly if the output of my program is always at the first line only of my database...
example... my problem is i will type a country code:
Enter Country Code : US (e.g.)
/* the answer will be like this.. */
United States: Digicel, Movistar and other telephone companies in that country,,
Enter Country Code: US(e.g.)
Afghanistan //this is always the reply of my input..
(at my database)
hmmm. it is something like this...
AF - Afghanistan
AX- Aland islands
PH - Philippines: Cure, Globe, Smart, Sun
US - United States: Digicel, Movistar etc...