Hi guys. I keep receiving problems when copying characters from an array to another. I'm using Visual C++ 6.0 on Windows XP Home Edition. I've also tested my code on Dev C++ and it does not work.
Input:Code:#include <iostream.h> #include <string.h> int main() { char word[20], perm[20]; int i, j, max; cin >> word; max = strlen(word); for(i = 0; i < max; ++i) word[i] = perm[i]; for(j = 0; j < max; ++j) cout << perm[j]; return 0; }
CALENDAR
Output:
ΜΜΜΜΜΜΜΜ
Thanks in advance.