When i'm trying to convert string to lowercase, non-english characters are converted to �
Take string from first file, convert it to lowercase and print in second file.
Let's say first line would be:
1.Testing Strings For Conversion
2.Test Des Chaînes Pour La Conversion
(French google translate)
main(){
ifstream old_file;
ofstream new_file;
string str;
old_file.open("first.txt");
new_file.open("second.txt");
getline(old_file, str);
transform(str.begin(), str.end(), str.begin(), ::tolower);
new_file << str;
old_file.close()
new_file.close()
}
Result will be:
1.testing strings for conversion
2.test des cha�nes pour la conversion
Input file encoding "UTF-8 with BOM"