I am looking at the example given for std::tolower in c++ reference and it seems the method std::tolower works even if I replace library <locale> with <algorithm>
Is <locale> imported indirectly if <algorithm> is included?
Example:
// tolower example (C++)
#include <iostream>
#include <string>
#include <locale> // <-- works for std::locale, std::tolower
#include <algorithm> // <-- also works for std::tolower
int main ()
{
std::locale loc;
std::string str="Test String.\n";
for (std::string::size_type i=0; i<str.length(); ++i)
std::cout << std::tolower(str[i],loc);
return 0;
}