Skip to Main Content
Professional C++, 6th Edition
book

Professional C++, 6th Edition

by Marc Gregoire
February 2024
Intermediate to advanced content levelIntermediate to advanced
1376 pages
40h 6m
English
Wiley
Content preview from Professional C++, 6th Edition

21String Localization and Regular Expressions

This chapter starts with a discussion of localization, which allows you to write software that can be localized to different regions around the world. An application that is properly localized displays numbers, dates, currencies, and so on in the appropriate format according to rules for a specific country or region.

The second part of this chapter introduces the regular expressions library, which makes it easy to perform pattern matching on strings. It allows you to search for substrings matching a given pattern, but also to validate, parse, and transform strings. Regular expressions are powerful. I recommend that you use them, as they are less error prone than manually writing your own string processing code.

LOCALIZATION

When you're learning how to program in C or C++, it's useful to think of a character as equivalent to a byte and to treat all characters as members of the American Standard Code for Information Interchange (ASCII) character ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Programming: Principles and Practice Using C++, 3rd Edition

Programming: Principles and Practice Using C++, 3rd Edition

Bjarne Stroustrup
C++ Primer, Fifth Edition

C++ Primer, Fifth Edition

Stanley B. Lippman, Josée Lajoie, Barbara E. Moo

Publisher Resources

ISBN: 9781394193172