Skip to content
masterclass Buddy

NumPy · Function

np.flip

numpy.flip reverses array elements along selected axes while preserving the array shape. It returns a view, and it can reverse one axis, several axes, or all axes.

Last updated

Syntax

numpy.flip(m, axis=None)

In-depth API docs are only for subscribers: parameters, examples, common mistakes and interview practice.

Subscribe
  • flipud
  • fliplr

Source: numpy.flip — NumPy v2.5 Manual. Checked 2026-11-03.