input: Write a python function to perform linear regression using numpy to find the slope and intercept of the line that best fits the given data points.
  assert linearRegression([0, 1, 2], [0, 1, 2]) == (1.0, 0.0)
  assert linearRegression([1, 2, 3], [2, 2, 2]) == (0.0, 2.0)
  assert linearRegression([1, 2, 3], [1, 2, 3]) == (1.0, 0.0)
  assert linearRegression([1, 2, 3], [3, 2, 1]) == (-1.0, 4.0)
output: import numpy as np
  
  def linearRegression(x, y):
      x = np.array(x)
      y = np.array(y)
      n = len(x)
      m = (n * np.sum(x*y) - np.sum(x) * np.sum(y)) / (n * np.sum(x**2) - np.sum(x)**2)
      b = (np.sum(y) - m * np.sum(x)) / n
      return m, b