Hello all. Getting to the point, I need some help in string functions. I was making a program to implement my own string functions, without using string.h
The program turns out proper and correct, but one little flaw remains and that appears in the execution. For this snippet of code -:
The computer accepts only one string and not the other. Why is this so? Even if I tryCode:cout << "\nEnter 2 strings - "; gets(str1); fflush(stdin); gets(str2); fflush(stdin);
It doesn't work. Will be grateful if you help ASAP.Code:cout << "\nEnter 1 string - "; gets(str1); fflush(stdin); cout << "\nEnter 2nd string - "; gets(str2); fflush(stdin);