protected

Usage protected access specifier

Type

Objects, references, functions including function template specializations, and expressions have a property called type, which both restricts the operations that are permitted for those entities and provides semantic meaning to the otherwise generic sequences of bits. Type classification The C++ type system consists of the following types: fundamental types (see also std::is_fundamental): the type void (see also std::is_void); the type std::nullptr_t (see also std::is_null_pointer); a

std::locale

Defined in header <locale> class locale; An object of class std::locale is an immutable indexed set of immutable facets. Each stream object of the C++ input/output library is associated with an std::locale object and uses its facets for parsing and formatting of all data. In addition, a locale object is associated with each std::basic_regex object. Locale objects can also be used as predicates that perform string collation with the standard containers and algorithms and can

std::iswalpha

Defined in header <cwctype> int iswalpha( std::wint_t ch ); Checks if the given wide character is an alphabetic character, i.e. either an uppercase letter (ABCDEFGHIJKLMNOPQRSTUVWXYZ), a lowercase letter (abcdefghijklmnopqrstuvwxyz) or any alphabetic character specific to the current locale. Parameters ch - wide character Return value Non-zero value if the wide character is a alphabetic character, 0 otherwise. Example #include <iostream> #include &l

Arithmetic operators

Returns the result of specific arithmetic operation. Operator name Syntax Over​load​able Prototype examples (for class T) Inside class definition Outside class definition unary plus +a Yes T T::operator+() const; T operator+(const T &a); unary minus -a Yes T T::operator-() const; T operator-(const T &a); addition a + b Yes T T::operator+(const T2 &b) const; T operator+(const T &a, const T2 &b); subtraction a - b Yes T T::operator-

friend

Usage friend specifier

auto specifier

Specifies that the type of the variable that is being declared will be automatically deduced from its initializer. For functions, specifies that the return type is a trailing return type or will be deduced from its return statements (since C++14). Syntax auto variable initializer (1) (since C++11) auto function -> return type (2) (since C++11) auto function (3) (since C++14) decltype(auto) variable initializer (4) (since C++14) decltype(auto) function (5) (sin

std::wcsrchr

Defined in header <cwchar> const wchar_t* wcsrchr( const wchar_t* str, wchar_t ch ); wchar_t* wcsrchr( wchar_t* str, wchar_t ch ); Finds the last occurrence of the wide character ch in the wide string pointed to by str. Parameters str - pointer to the null-terminated wide string to be analyzed ch - wide character to search for Return value Pointer to the found character in str, or NULL if no such character is found. Example See als

std::ctype&lt;char&gt;::scan_is

Defined in header <locale> const char* scan_not (mask m, const char* beg, const char* end) const; (1) Locates the first character in the character array [beg, end) that does not satisfy the classification mask m, that is, the first character c such that table()[(unsigned char)c] & m would return false. If (unsigned char)c >= std::ctype<char>::table_size, then an implementation-defined value is substituted instead of table()[(unsigned char)c], possibly different

std::stack::top

reference top(); const_reference top() const; Returns reference to the top element in the stack. This is the most recently pushed element. This element will be removed on a call to pop(). Effectively calls c.back(). Parameters (none). Return value Reference to the last element. Complexity Constant. Example #include <stack> #include <iostream> int main() { std::stack<int> s; s.push( 2 ); s.push( 6 ); s.push( 51 ); std::cou