human
Write me a Python program for selecting from different dimensions of an array.
assistant
Here is a Python program for selecting from different dimensions of an array

import numpy as np

def select_array(array, indices):
    """
    Return a slice of an array.
    """
    return array[indices]

# Enter the array
array = np.array([[1, 2, 3], [4, 5, 6]])

# Enter the indices
indices = [0, 1]

# Calling the function
print((select_array(array, indices)))

#Example Output
# [[1 2 3]
#  [4 5 6]]

#Remember to inspect code for bugs.