Built-in functions and Library utilities in arrays:
Built-in functions and library utilities are predefined in standard files. It mainly manipulates arrays in terms of sorting, searching and so on. The standard functions are given below. Header file : <algorithm> and <numeric> Functions: ‘std::sort(array,size)’ – this function sorts the array in ascending order. ‘std::reverse(array,size)’ – it reverses the array. ‘std:: accumulate(array, array + size, 0)’ – it adds the array elements together. ‘ std::find(array, array + size, value)’- it finds a particular element in the array. ‘ std::binary_search(array, array + size, value)’- it uses the binary search to find an element. ‘ arr.size()’ -it gives you the size of the array. ‘ arr.at(2)’- a particular element is accessed. ‘ arr.fill(1)’- it fills 1 for all elements. ‘ arr.swap(arr2)’ – it swaps the element between two arrays. ‘sizeof(array)’ – it gives the size of the array. ‘memset(array...