input: Write a python function to create, compile, and train a neural network using TensorFlow Keras.
  assert create_and_train_model(np.random.random((60000, 784)), np.random.randint(10, size=60000), np.random.random((10000, 784)), np.random.randint(10, size=10000)) is not None
output: import tensorflow as tf
  from tensorflow.keras.models import Sequential
  from tensorflow.keras.layers import Dense
  from tensorflow.keras.optimizers import Adam
  
  def create_and_train_model(x_train, y_train, x_test, y_test):
      # Create a simple neural network model
      model = Sequential([
          Dense(128, activation='relu', input_shape=(784,)),
          Dense(64, activation='relu'),
          Dense(10, activation='softmax')
      ])
      
      # Compile the model
      model.compile(optimizer=Adam(), loss='sparse_categorical_crossentropy', metrics=['accuracy'])
      
      # Train the model
      model.fit(x_train, y_train, epochs=10, validation_data=(x_test, y_test))
      
      return model