On 11 July 2011 13:28, Eric Lin wrote: > http://examples.oreilly.com/9780596007614/ > both book and last time I copied, that example code did not have > #include <locale> So what? The example might be wrong, and in this case it definitely is. If the compiler complains about an undefined type, make sure you are including the correct header for that type. Do not assume the example is correct. Learn to find which header defines the type - if you want to be a C++ programmer you NEED to do that, you cannot send an email every time you get a compilation error.