std::array::back

reference back(); (since C++11) const_reference back() const; (since C++11) (until C++14) constexpr const_reference back() const; (since C++14) Returns reference to the last element in the container. Calling back on an empty container is undefined. Parameters (none). Return value Reference to the last element. Complexity Constant. Notes For a container c, the expression return c.back(); is equivalent to { auto tmp = c.end(); --tmp; return *tmp; } Example The

std::array::at

reference at( size_type pos ); (since C++11) const_reference at( size_type pos ) const; (since C++11) (until C++14) constexpr const_reference at( size_type pos ) const; (since C++14) Returns a reference to the element at specified location pos, with bounds checking. If pos not within the range of the container, an exception of type std::out_of_range is thrown. Parameters pos - position of the element to return Return value Reference to the requested eleme

std::array

Defined in header <array> template< class T, std::size_t N > struct array; (since C++11) std::array is a container that encapsulates fixed size arrays. This container is an aggregate type with the same semantics as a struct holding a C-style array T[N] as its only non-static data member. Unlike a C-style array, it doesn't decay to T* automatically. As an aggregate type, it can be initialized with aggregate-initialization given at most N initializers that ar

std::allocator_traits::deallocate

Defined in header <memory> static void deallocate( Alloc& a, pointer p, size_type n ); (since C++11) Uses the allocator a to deallocate the storage referenced by p, by calling a.deallocate(p, n). Parameters a - allocator to use p - pointer to the previously allocated storage n - the number of objects the storage was allocated for Return value (none). See also allocate [static] allocates uninitialized storage using the allocator (public

std::all_of

Defined in header <algorithm> template< class InputIt, class UnaryPredicate > bool all_of( InputIt first, InputIt last, UnaryPredicate p ); (1) (since C++11) template< class InputIt, class UnaryPredicate > bool any_of( InputIt first, InputIt last, UnaryPredicate p ); (2) (since C++11) template< class InputIt, class UnaryPredicate > bool none_of( InputIt first, InputIt last, UnaryPredicate p ); (3) (since C++11) 1) Checks if unary predicate p r

std::allocator_traits::select_on_container_copy_construction

Defined in header <memory> static Alloc select_on_container_copy_construction( const Alloc& a ); (since C++11) If possible, obtains the copy-constructed version of the allocator a, by calling a.select_on_container_copy_construction(). If the above is not possible (e.g. a does not have the member function select_on_container_copy_construction(), then returns a, unmodified. This function is called by the copy constructors of all standard library containers. It allows the

std::allocator_traits::max_size

Defined in header <memory> static size_type max_size( const Alloc& a ); (since C++11) If possible, obtains the maximum theoretically possible allocation size from the allocator a, by calling. a.max_size(). If the above is not possible (e.g. a does not have the member function max_size()), then returns std::numeric_limits<size_type>::max() (until C++17)std::numeric_limits<size_type>::max() / sizeof(value_type) (since C++17). Parameters (none). Return v

std::allocator_traits::destroy

Defined in header <memory> template< class T > static void destroy( Alloc& a, T* p ); (since C++11) Calls the destructor of the object pointed to by p. If possible, does so by calling a.destroy(p). If not possible (e.g. a does not have the member function destroy(), then calls the destructor of *p directly, as p->~T(). Parameters a - allocator to use for destruction p - pointer to the object being destroyed Return value (none). Notes Beca

std::arg(std::complex)

Defined in header <complex> template< class T > T arg( const complex<T>& z ); (1) long double arg( long double z ); (2) (since C++11) template< class DoubleOrIngeter > double arg( DoubleOrInteger z ); (3) (since C++11) float arg( float z ); (4) (since C++11) Calculates the phase angle (in radians) of the complex number z. (since C++11)Additional overloads are provided for float, double, long double, and all integer types, which are t

std::allocator_traits

Defined in header <memory> template< class Alloc > struct allocator_traits; (since C++11) The allocator_traits class template provides the standardized way to access various properties of allocators. The standard containers and other standard library components access allocators through this template, which makes it possible to use any class type as an allocator, as long as the user-provided specialization of allocator_traits implements all required functionality. The