Python NumPy flip() is an inbuilt  NumPy function that is used to reverse the order of array elements by keeping the shape of the array along a specified axis. The flip() function is defined under numpy, which can be imported as import numpy as np, and we can create multidimensional arrays and derive other mathematical statistics with the help of numpy, which is a library in Python.

Python NumPy flip()

NumPy flip() function is used to reverse the order of items in the array along the given axis. The shape of an array is preserved, but the items are reordered.


numpy.flip(array, axis( axis on which array is to be reversed))

#python #numpy

Python NumPy flip() Function Example
8.05 GEEK