input: Write a function to construct a neural network model in Python using Keras that correctly classifies the MNIST data set. The model should have an input layer, a hidden layer with 128 neurons and ReLU activation, and an output layer with 10 neurons and softmax activation. The model should be compiled with the Adam optimizer, sparse categorical cross-entropy loss, and accuracy as the metric.
  
  assert construct_mnist_model().input.shape[1]==784
  assert construct_mnist_model().output_shape[1]==10
  assert construct_mnist_model().layers[1].units==128
  assert construct_mnist_model().layers[1].activation.__name__=='relu'
  assert construct_mnist_model().layers[2].activation.__name__=='softmax'
output: def construct_mnist_model():
      from tensorflow.keras.models import Sequential
      from tensorflow.keras.layers import Dense
      model = Sequential()
      model.add(Dense(128, activation='relu', input_shape=(784,)))
      model.add(Dense(10, activation='softmax'))
      model.compile(optimizer='adam', loss='sparse_categorical_crossentropy', metrics=['accuracy'])
      return model